From 57a9a420eeffdb20681514ae749cc8b4770dbd45 Mon Sep 17 00:00:00 2001 From: Don Allingham Date: Sat, 31 Jan 2004 21:32:01 +0000 Subject: [PATCH] * src/PeopleView.py (PeopleView.add_to_person_list): don't attempt to sort the model unless it has be assigned. svn: r2731 --- gramps2/src/PeopleView.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/gramps2/src/PeopleView.py b/gramps2/src/PeopleView.py index 8a10e8fcb..33a270216 100644 --- a/gramps2/src/PeopleView.py +++ b/gramps2/src/PeopleView.py @@ -189,6 +189,7 @@ class PeopleView: val = self.parent.db.getPersonDisplay(person.getId()) pg = unicode(val[5]) pg = pg[0] + model = None if self.DataFilter.compare(person): if pg and pg != '@': @@ -206,7 +207,8 @@ class PeopleView: if change: self.parent.change_active_person(person) self.goto_active_person() - model.enable_sort() + if model: + model.enable_sort() def goto_active_person(self,first=0): if not self.parent.active_person: