Use appropriate friend methods.
authorAndrew Flegg <andrew@bleb.org>
Wed, 9 Jun 2010 22:52:16 +0000 (23:52 +0100)
committerAndrew Flegg <andrew@bleb.org>
Wed, 9 Jun 2010 22:52:16 +0000 (23:52 +0100)
package/src/org/maemo/hermes/engine/hermes.py

index e4b4713..c9c4c91 100644 (file)
@@ -149,10 +149,11 @@ class Hermes:
     # -----------------------------------------------------------------------
     def _create_empty_contact(self, friend):
         econtact = evolution.ebook.EContact()
-        econtact.props.full_name = friend['name']
         econtact.props.given_name = friend['first_name']
         econtact.props.family_name = friend['last_name']
+        econtact.props.full_name = friend.get_name()
+        return econtact
     
     # -----------------------------------------------------------------------
     def _create_contact_wrapper(self, econtact):
-        return Contact(self.address_book, econtact)
\ No newline at end of file
+        return Contact(self.address_book, econtact)