Make :set work correctly
This commit is contained in:
parent
e9317f807b
commit
a0a8f5d025
1
TODO
1
TODO
@ -2,7 +2,6 @@ New config TODO
|
|||||||
===============
|
===============
|
||||||
|
|
||||||
- Changing models is awfully slow
|
- Changing models is awfully slow
|
||||||
- Add correctly working :get and :set commands
|
|
||||||
- Implement different layers of config options correctly, not only default.
|
- Implement different layers of config options correctly, not only default.
|
||||||
|
|
||||||
Bugs
|
Bugs
|
||||||
|
@ -219,11 +219,8 @@ class Config:
|
|||||||
if value:
|
if value:
|
||||||
value = self._interpolation.before_set(self, section, option,
|
value = self._interpolation.before_set(self, section, option,
|
||||||
value)
|
value)
|
||||||
if not section or section == self.default_section:
|
|
||||||
sectdict = self._defaults
|
|
||||||
else:
|
|
||||||
try:
|
try:
|
||||||
sectdict = self._sections[section]
|
sectdict = self.config[section]
|
||||||
except KeyError:
|
except KeyError:
|
||||||
raise NoSectionError(section)
|
raise NoSectionError(section)
|
||||||
sectdict[self.optionxform(option)] = value
|
sectdict[self.optionxform(option)] = value
|
||||||
|
Loading…
Reference in New Issue
Block a user