diff --git a/obexd/plugins/phonebook-tracker.c b/obexd/plugins/phonebook-tracker.c
index 6e35399..9453cd7 100644
--- a/obexd/plugins/phonebook-tracker.c
+++ b/obexd/plugins/phonebook-tracker.c
"?suffix ?email " \
"WHERE { " \
"?contact a nco:PersonContact ; " \
- "nco:nameFamily ?family ; " \
- "nco:nameGiven ?given ; " \
- "nco:fullname ?fullname ; " \
"nco:hasPhoneNumber ?phone . " \
+ "OPTIONAL { ?contact nco:nameFamily ?family } " \
+ "OPTIONAL { ?contact nco:nameGiven ?given } " \
+ "OPTIONAL { ?contact nco:fullname ?fullname } " \
"OPTIONAL { ?contact nco:hasEmailAddress ?email } " \
"OPTIONAL { ?contact nco:nameAdditional ?additional } " \
"OPTIONAL { ?contact nco:nameHonorificPrefix ?prefix } " \
"?suffix ?phone " \
"WHERE { " \
"?contact a nco:PersonContact ; " \
- "nco:nameFamily ?family ; " \
- "nco:nameGiven ?given ; " \
"nco:hasPhoneNumber ?phone . " \
+ "OPTIONAL { ?contact nco:nameFamily ?family } " \
+ "OPTIONAL { ?contact nco:nameGiven ?given } " \
"OPTIONAL { ?contact nco:nameAdditional ?additional } " \
"OPTIONAL { ?contact nco:nameHonorificPrefix ?prefix } " \
"OPTIONAL { ?contact nco:nameHonorificSuffix ?suffix } " \
"nmo:isSent false ; " \
"nmo:isAnswered false ." \
"?contact a nco:PersonContact ; " \
- "nco:nameFamily ?family ; " \
- "nco:nameGiven ?given ; " \
- "nco:fullname ?fullname ; " \
"nco:hasPhoneNumber ?phone . " \
+ "OPTIONAL { ?contact nco:nameFamily ?family } " \
+ "OPTIONAL { ?contact nco:nameGiven ?given } " \
+ "OPTIONAL { ?contact nco:fullname ?fullname } " \
"OPTIONAL { ?contact nco:hasEmailAddress ?email } " \
"OPTIONAL { ?contact nco:nameAdditional ?additional } " \
"OPTIONAL { ?contact nco:nameHonorificPrefix ?prefix } " \
"nmo:isSent false ; " \
"nmo:isAnswered false ." \
"?contact a nco:PersonContact ; " \
- "nco:nameFamily ?family ; " \
- "nco:nameGiven ?given ; " \
"nco:hasPhoneNumber ?phone . " \
+ "OPTIONAL { ?contact nco:nameFamily ?family } " \
+ "OPTIONAL { ?contact nco:nameGiven ?given } " \
"OPTIONAL { ?contact nco:hasEmailAddress ?email } " \
"OPTIONAL { ?contact nco:nameAdditional ?additional } " \
"OPTIONAL { ?contact nco:nameHonorificPrefix ?prefix } " \
"nmo:from ?contact ; " \
"nmo:isSent false . " \
"?contact a nco:PersonContact ; " \
- "nco:nameFamily ?family ; " \
- "nco:nameGiven ?given ; " \
- "nco:fullname ?fullname ; " \
"nco:hasPhoneNumber ?phone . " \
+ "OPTIONAL { ?contact nco:nameFamily ?family } " \
+ "OPTIONAL { ?contact nco:nameGiven ?given } " \
+ "OPTIONAL { ?contact nco:fullname ?fullname } " \
"OPTIONAL { ?contact nco:hasEmailAddress ?email } " \
"OPTIONAL { ?contact nco:nameAdditional ?additional } " \
"OPTIONAL { ?contact nco:nameHonorificPrefix ?prefix } " \
"nmo:from ?contact ; " \
"nmo:isSent false . " \
"?contact a nco:PersonContact ; " \
- "nco:nameFamily ?family ; " \
- "nco:nameGiven ?given ; " \
"nco:hasPhoneNumber ?phone . " \
+ "OPTIONAL { ?contact nco:nameFamily ?family } " \
+ "OPTIONAL { ?contact nco:nameGiven ?given } " \
"OPTIONAL { ?contact nco:nameAdditional ?additional } " \
"OPTIONAL { ?contact nco:nameHonorificPrefix ?prefix } " \
"OPTIONAL { ?contact nco:nameHonorificSuffix ?suffix } " \
"nmo:to ?contact ; " \
"nmo:isSent true . " \
"?contact a nco:PersonContact ; " \
- "nco:nameFamily ?family ; " \
- "nco:nameGiven ?given ; " \
- "nco:fullname ?fullname ; " \
"nco:hasPhoneNumber ?phone . " \
+ "OPTIONAL { ?contact nco:nameFamily ?family } " \
+ "OPTIONAL { ?contact nco:nameGiven ?given } " \
+ "OPTIONAL { ?contact nco:fullname ?fullname } " \
"OPTIONAL { ?contact nco:hasEmailAddress ?email } " \
"OPTIONAL { ?contact nco:nameAdditional ?additional } " \
"OPTIONAL { ?contact nco:nameHonorificPrefix ?prefix } " \
"nmo:to ?contact ; " \
"nmo:isSent true . " \
"?contact a nco:PersonContact ; " \
- "nco:nameFamily ?family ; " \
- "nco:nameGiven ?given ; " \
"nco:hasPhoneNumber ?phone . " \
+ "OPTIONAL { ?contact nco:nameFamily ?family } " \
+ "OPTIONAL { ?contact nco:nameGiven ?given } " \
"OPTIONAL { ?contact nco:nameAdditional ?additional } " \
"OPTIONAL { ?contact nco:nameHonorificPrefix ?prefix } " \
"OPTIONAL { ?contact nco:nameHonorificSuffix ?suffix } " \
"nmo:to ?contact ; " \
"nmo:isSent true . " \
"?contact a nco:PersonContact ; " \
- "nco:nameFamily ?family ; " \
- "nco:nameGiven ?given ; " \
- "nco:fullname ?fullname ; " \
"nco:hasPhoneNumber ?phone . " \
+ "OPTIONAL { ?contact nco:nameFamily ?family } " \
+ "OPTIONAL { ?contact nco:nameGiven ?given } " \
+ "OPTIONAL { ?contact nco:fullname ?fullname } " \
"OPTIONAL { ?contact nco:hasEmailAddress ?email } " \
"OPTIONAL { ?contact nco:nameAdditional ?additional } " \
"OPTIONAL { ?contact nco:nameHonorificPrefix ?prefix } "\
"nmo:from ?contact ; " \
"nmo:isSent false . " \
"?contact a nco:PersonContact ; " \
- "nco:nameFamily ?family ; " \
- "nco:nameGiven ?given ; " \
- "nco:fullname ?fullname ; " \
"nco:hasPhoneNumber ?phone . " \
+ "OPTIONAL { ?contact nco:nameFamily ?family } " \
+ "OPTIONAL { ?contact nco:nameGiven ?given } " \
+ "OPTIONAL { ?contact nco:fullname ?fullname } " \
"OPTIONAL { ?contact nco:hasEmailAddress ?email } " \
"OPTIONAL { ?contact nco:nameAdditional ?additional } " \
"OPTIONAL { ?contact nco:nameHonorificPrefix ?prefix } "\
"nmo:to ?contact ; " \
"nmo:isSent true . " \
"?contact a nco:PersonContact ; " \
- "nco:nameFamily ?family ; " \
- "nco:nameGiven ?given ; " \
"nco:hasPhoneNumber ?phone . " \
+ "OPTIONAL { ?contact nco:nameFamily ?family } " \
+ "OPTIONAL { ?contact nco:nameGiven ?given } " \
"OPTIONAL { ?contact nco:nameAdditional ?additional } " \
"OPTIONAL { ?contact nco:nameHonorificPrefix ?prefix } "\
"OPTIONAL { ?contact nco:nameHonorificSuffix ?suffix } "\
"nmo:from ?contact ; " \
"nmo:isSent false . " \
"?contact a nco:PersonContact ; " \
- "nco:nameFamily ?family ; " \
- "nco:nameGiven ?given ; " \
"nco:hasPhoneNumber ?phone . " \
+ "OPTIONAL { ?contact nco:nameFamily ?family } " \
+ "OPTIONAL { ?contact nco:nameGiven ?given } " \
"OPTIONAL { ?contact nco:nameAdditional ?additional } " \
"OPTIONAL { ?contact nco:nameHonorificPrefix ?prefix } "\
"OPTIONAL { ?contact nco:nameHonorificSuffix ?suffix } "\
" ?suffix ?email " \
"WHERE { " \
"<%s> a nco:PersonContact ; " \
- "nco:nameFamily ?family ; " \
- "nco:nameGiven ?given ; " \
- "nco:fullname ?fullname ; " \
"nco:hasPhoneNumber ?phone . " \
+ "OPTIONAL { <%s> nco:nameFamily ?family } " \
+ "OPTIONAL { <%s> nco:nameGiven ?given } " \
+ "OPTIONAL { <%s> nco:fullname ?fullname } " \
"OPTIONAL { <%s> nco:hasEmailAddress ?email } " \
"OPTIONAL { <%s> nco:nameAdditional ?additional } " \
"OPTIONAL { <%s> nco:nameHonorificPrefix ?prefix } " \
data->params = params;
data->cb = cb;
- query = g_strdup_printf(CONTACTS_QUERY_FROM_URI, id, id, id, id, id);
+ query = g_strdup_printf(CONTACTS_QUERY_FROM_URI,
+ id, id, id, id, id, id, id, id);
ret = query_tracker(query, 8, pull_contacts, data);;