diff options
author | Xisco Fauli <anistenis@gmail.com> | 2013-06-09 21:52:24 +0200 |
---|---|---|
committer | Xisco Fauli <anistenis@gmail.com> | 2013-06-09 22:08:11 +0200 |
commit | fd6f7ce9d0110f23aff6fd7788eef7010eb564cb (patch) | |
tree | ee5c12f6c62d98aee6991e18bc4281d7433e6d1c /wizards | |
parent | c8ff89fa3ac8b1c2a6725d5c6ebaeb7b3d74845e (diff) |
pyweb: Handle Keyerror exception
Change-Id: I16ea149917b911ba074415511d1f5053439c33bb
(cherry picked from commit 11a560967f11f10ec570f665d0e65e17f124912a)
Diffstat (limited to 'wizards')
-rw-r--r-- | wizards/com/sun/star/wizards/web/WWD_Events.py | 1 | ||||
-rw-r--r-- | wizards/com/sun/star/wizards/web/WebConfigSet.py | 5 | ||||
-rw-r--r-- | wizards/com/sun/star/wizards/web/WebWizard.py | 1 |
3 files changed, 5 insertions, 2 deletions
diff --git a/wizards/com/sun/star/wizards/web/WWD_Events.py b/wizards/com/sun/star/wizards/web/WWD_Events.py index ded74665ed1e..0e75c2388a41 100644 --- a/wizards/com/sun/star/wizards/web/WWD_Events.py +++ b/wizards/com/sun/star/wizards/web/WWD_Events.py @@ -19,7 +19,6 @@ import traceback import uno import time -#from common.Desktop import Desktop from .WWD_Startup import WWD_Startup from .WWD_General import WWD_General from .WebWizardConst import * diff --git a/wizards/com/sun/star/wizards/web/WebConfigSet.py b/wizards/com/sun/star/wizards/web/WebConfigSet.py index 1c73761f851b..92640dde05c1 100644 --- a/wizards/com/sun/star/wizards/web/WebConfigSet.py +++ b/wizards/com/sun/star/wizards/web/WebConfigSet.py @@ -147,7 +147,10 @@ class WebConfigSet(ConfigGroup): return self.childrenList[i] def getElement(self, o): - return self.childrenMap[o] + try: + return self.childrenMap[o] + except KeyError: + return None def getSize(self): return len(self.childrenList) diff --git a/wizards/com/sun/star/wizards/web/WebWizard.py b/wizards/com/sun/star/wizards/web/WebWizard.py index 241e776bb002..a576ea812319 100644 --- a/wizards/com/sun/star/wizards/web/WebWizard.py +++ b/wizards/com/sun/star/wizards/web/WebWizard.py @@ -17,6 +17,7 @@ # import traceback +from ..common.Desktop import Desktop from .WWD_Events import WWD_Events # The last class in the WebWizard Dialog class hirarchy. |