* src/plugins/Ancestors.py (event_info): Check whetehr place

exists before getting its title (#1014412).


svn: r3489
This commit is contained in:
Alex Roitman 2004-08-23 17:04:14 +00:00
parent 5789b1a54a
commit 72ca6d58da
2 changed files with 7 additions and 3 deletions

View File

@ -8,6 +8,8 @@
* src/plugins/IndivComplete.py (write_alt_names): Correct the
use of handle (#1014411); (write_fact, write_sources, write_person):
Use gramps id, not handle, for displaying source references.
* src/plugins/Ancestors.py (event_info): Check whetehr place
exists before getting its title (#1014412).
2004-08-23 Tim Waugh <twaugh@redhat.com>
* install-sh: Removed this generated file.

View File

@ -452,9 +452,11 @@ class ComprehensiveAncestorsReport (Report.Report):
info += _(' in %(month_or_year)s') % \
{'month_or_year': dateobj.get_date ()}
placename = self.database.get_place_from_handle(event.get_place_handle()).get_title()
if placename:
info += _(' in %(place)s') % {'place': placename}
place = self.database.get_place_from_handle(event.get_place_handle())
if place:
placename = place.get_title()
if placename:
info += _(' in %(place)s') % {'place': placename}
note = event.get_note ()
note_format = event.get_note_format ()
inline_note = note and (note_format == 0)