Diff between 6b7b19c97220a040ee5fe3e9e77f08a43c9073fb and df0740c34e4b4605831523d153969ccf89f007c3

Changed Files

File Additions Deletions Status
obexd/plugins/phonebook-tracker.c +3 -3 modified

Full Patch

diff --git a/obexd/plugins/phonebook-tracker.c b/obexd/plugins/phonebook-tracker.c
index 8bc070f..875901c 100644
--- a/obexd/plugins/phonebook-tracker.c
+++ b/obexd/plugins/phonebook-tracker.c
@@ -164,7 +164,7 @@
 	"?_unb_contact nco:hasPhoneNumber ?_cpn . "			\
 CONSTRAINT								\
 	"OPTIONAL { "							\
-		"{ SELECT ?_contact ?_cpn ?_role ?_number "		\
+		"{ SELECT ?_contact ?_no ?_role ?_number "		\
 			"count(?_contact) as ?cnt "			\
 		"WHERE { "						\
 			"?_contact a nco:PersonContact . "		\
@@ -175,9 +175,9 @@ CONSTRAINT								\
 				"?_contact nco:hasPhoneNumber ?_number" \
 			"} "						\
 			"?_number maemo:localPhoneNumber ?_no . "	\
-			"?_cpn maemo:localPhoneNumber ?_no . "		\
-		"} GROUP BY ?_cpn } "					\
+		"} GROUP BY ?_no } "					\
 		"FILTER(?cnt = 1) "					\
+		"?_cpn maemo:localPhoneNumber ?_no . "			\
 	"} "								\
 "} "