diff options
Diffstat (limited to 'setup/prefs.py')
-rw-r--r-- | setup/prefs.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/setup/prefs.py b/setup/prefs.py index f3f0781..66f2cd6 100644 --- a/setup/prefs.py +++ b/setup/prefs.py @@ -57,6 +57,10 @@ class Prefs(object): return self.default[section][key] def set_value(self, section, key, value): + if section not in self.sections(): + self.set_new_section(section) + if key not in self.keys(section): + self.set_new_key(section, key) self.default[section][key] self.new.setdefault(section, {})[key] = value |