diff options
Diffstat (limited to 'addressbook/gui/contact-editor')
-rw-r--r-- | addressbook/gui/contact-editor/e-contact-editor.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/addressbook/gui/contact-editor/e-contact-editor.c b/addressbook/gui/contact-editor/e-contact-editor.c index 4cdf1e2185..f545594039 100644 --- a/addressbook/gui/contact-editor/e-contact-editor.c +++ b/addressbook/gui/contact-editor/e-contact-editor.c @@ -2247,7 +2247,16 @@ set_address_label (EContact *contact, { gchar *address_label = NULL; - if (address) { + if (!address) { + e_contact_set (contact, field, NULL); + return; + } + + address_label = eab_format_address (contact, + (field == E_CONTACT_ADDRESS_LABEL_WORK) ? E_CONTACT_ADDRESS_WORK : + E_CONTACT_ADDRESS_HOME); + + if (!address_label) { address_label = append_to_address_label ( address_label, address->street, TRUE); address_label = append_to_address_label ( |