diff options
author | Niels De Graef <nielsdegraef@gmail.com> | 2018-04-25 21:03:46 +0200 |
---|---|---|
committer | Niels De Graef <nielsdegraef@gmail.com> | 2018-04-25 21:03:46 +0200 |
commit | 0102b42170c0e639931c5382724146e87bcf1076 (patch) | |
tree | 9cf82214e94772f739c00b89e6f0722a61a8e244 | |
parent | fff46f225d254888833cc995a2756a6e860f8292 (diff) | |
download | gnome-contacts-wip/nielsdg/converge-editor-and-sheet.tar.gz |
ContactSheet: solve Critical with an empty first persona.wip/nielsdg/converge-editor-and-sheet
-rw-r--r-- | src/contacts-contact-sheet.vala | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/contacts-contact-sheet.vala b/src/contacts-contact-sheet.vala index 37ff5c3..3677dee 100644 --- a/src/contacts-contact-sheet.vala +++ b/src/contacts-contact-sheet.vala @@ -126,12 +126,12 @@ public class Contacts.ContactSheet : ContactForm { foreach (var prop in ContactForm.SORTED_PROPERTIES) add_row_for_property (p, prop); - if (this.last_row != 3) - is_first_persona = false; - // Nothing to show in the persona: don't mention it - if (this.last_row == persona_store_pos + 1) + if (!is_first_persona && this.last_row == persona_store_pos + 1) get_child_at (0, persona_store_pos).destroy (); + + if (this.last_row != 3) + is_first_persona = false; } show_all (); |