From dbc15d475ff75c83efd907776a8eccc7e22f04d2 Mon Sep 17 00:00:00 2001 From: Peter Landgren Date: Fri, 15 Oct 2010 17:57:07 +0000 Subject: [PATCH] Issue 4293, problems with LagecyGedcom and empty events. svn: r15998 --- src/gen/ggettext.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/gen/ggettext.py b/src/gen/ggettext.py index c3f3d471f..293f4111e 100644 --- a/src/gen/ggettext.py +++ b/src/gen/ggettext.py @@ -41,6 +41,10 @@ def gettext(msgid): :returns: Translation or the original. :rtype: unicode """ + # If msgid =="" then gettext will return po file header + # and that's not what we want. + if len(msgid.strip()) == 0: + return msgid return unicode(pgettext.gettext(msgid)) def ngettext(singular, plural, n):