From a9cf1868756287c9db6e51b3cb05f3862bf1e428 Mon Sep 17 00:00:00 2001 From: helmutm Date: Mon, 12 Oct 2009 06:04:17 +0000 Subject: [PATCH] make configuration queries more fault-tolerant git-svn-id: svn://svn.cy55.de/Zope3/src/cybertools/trunk@3574 fd906abe-77d9-0310-91a1-e0d9ade77398 --- meta/config.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/meta/config.py b/meta/config.py index 003ac35..8a4a9ed 100644 --- a/meta/config.py +++ b/meta/config.py @@ -1,5 +1,5 @@ # -# Copyright (c) 2008 Helmut Merz helmutm@cy55.de +# Copyright (c) 2009 Helmut Merz helmutm@cy55.de # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -37,7 +37,7 @@ class Options(AutoNamespace): def __call__(self, key, default=None): value = self for part in key.split('.'): - value = getattr(value, part) + value = getattr(value, part, None) if isinstance(value, Element): value = default return value