From 3d2aa08782099cd95de1d072c68f2530163a9916 Mon Sep 17 00:00:00 2001 From: Stein Magnus Jodal Date: Sat, 20 Mar 2010 01:37:30 +0100 Subject: [PATCH] Only do settings checking on all-uppercase attributes (to please Sphinx) --- mopidy/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mopidy/__init__.py b/mopidy/__init__.py index 5770716f..5e7b9988 100644 --- a/mopidy/__init__.py +++ b/mopidy/__init__.py @@ -35,7 +35,7 @@ class SettingsError(Exception): class Settings(object): def __getattr__(self, attr): - if not hasattr(raw_settings, attr): + if attr.isupper() and not hasattr(raw_settings, attr): raise SettingsError(u'Setting "%s" is not set.' % attr) value = getattr(raw_settings, attr) if type(value) != bool and not value: