From 886f2d86821e3777bcbedbe1a1bf34fc77168927 Mon Sep 17 00:00:00 2001 From: Andrew Resch Date: Wed, 23 Dec 2009 01:34:58 +0000 Subject: [PATCH] Add in a '_' builtin method if unable to initialize gettext --- deluge/ui/gtkui/gtkui.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/deluge/ui/gtkui/gtkui.py b/deluge/ui/gtkui/gtkui.py index edcab6a80..255622afb 100644 --- a/deluge/ui/gtkui/gtkui.py +++ b/deluge/ui/gtkui/gtkui.py @@ -61,6 +61,8 @@ try: except Exception, e: log.error("Unable to initialize gettext/locale!") log.exception(e) + import __builtin__ + __builtin__.__dict__["_"] = lambda x: x import deluge.component as component from deluge.ui.client import client