summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorChris St. Pierre <chris.a.st.pierre@gmail.com>2012-01-24 10:44:32 -0500
committerChris St. Pierre <chris.a.st.pierre@gmail.com>2012-01-24 10:44:32 -0500
commit72598be3b8d32a2edbfc69ac36057e7b44d118bf (patch)
tree00159f10fdfe6bee8ff1e879af1c16f5423d7c70 /src
parent987fd6364887184bf201a0a68f6903cec6cc5d84 (diff)
downloadbcfg2-72598be3b8d32a2edbfc69ac36057e7b44d118bf.tar.gz
bcfg2-72598be3b8d32a2edbfc69ac36057e7b44d118bf.tar.bz2
bcfg2-72598be3b8d32a2edbfc69ac36057e7b44d118bf.zip
fixed metadata/resolver option defaults
Diffstat (limited to 'src')
-rw-r--r--src/lib/Server/Plugins/Packages/__init__.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/lib/Server/Plugins/Packages/__init__.py b/src/lib/Server/Plugins/Packages/__init__.py
index ae8dc54db..da5832e90 100644
--- a/src/lib/Server/Plugins/Packages/__init__.py
+++ b/src/lib/Server/Plugins/Packages/__init__.py
@@ -49,6 +49,8 @@ class Packages(Bcfg2.Server.Plugin.Plugin,
def disableResolver(self):
try:
return not self.config.getboolean("global", "resolver")
+ except (ConfigParser.NoSectionError, ConfigParser.NoOptionError):
+ return False
except ValueError:
# for historical reasons we also accept "enabled" and
# "disabled", which are not handled according to the
@@ -61,6 +63,8 @@ class Packages(Bcfg2.Server.Plugin.Plugin,
def disableMetaData(self):
try:
return not self.config.getboolean("global", "resolver")
+ except (ConfigParser.NoSectionError, ConfigParser.NoOptionError):
+ return False
except ValueError:
# for historical reasons we also accept "enabled" and
# "disabled"