aboutsummaryrefslogtreecommitdiff
path: root/lib/python/Components
diff options
context:
space:
mode:
authorAndreas Monzner <andreas.monzner@multimedia-labs.de>2006-01-27 23:22:45 +0000
committerAndreas Monzner <andreas.monzner@multimedia-labs.de>2006-01-27 23:22:45 +0000
commit9d8db8ae95434e94e745854d30bf624791151553 (patch)
tree34ece497bc6b6b60a840162be767913c6f549de0 /lib/python/Components
parent02c49e642a6bcc65d1cdc443510d9cfefdcfbe93 (diff)
downloadenigma2-9d8db8ae95434e94e745854d30bf624791151553.tar.gz
enigma2-9d8db8ae95434e94e745854d30bf624791151553.zip
revert getKey change..
Diffstat (limited to 'lib/python/Components')
-rw-r--r--lib/python/Components/config.py11
1 files changed, 6 insertions, 5 deletions
diff --git a/lib/python/Components/config.py b/lib/python/Components/config.py
index c06d3b72..06bb62a2 100644
--- a/lib/python/Components/config.py
+++ b/lib/python/Components/config.py
@@ -27,11 +27,9 @@ class configFile:
x = line.find("=")
if x > -1:
self.configElements[line[:x]] = line[x + 1:-1]
-
+
def getKey(self, key):
- if self.configElements.has_key(key):
- return self.configElements[key]
- return None
+ return self.configElements[key]
def setKey(self, key, value, isDefaultKey=False):
self.changed = 1
@@ -558,7 +556,10 @@ class configElement:
if self.value != defaultValue or self.saveDefaults:
configfile.setKey(self.configPath, self.datatoFile(self.controlType, self.value))
else:
- oldValue = configfile.getKey(self.configPath)
+ try:
+ oldValue = configfile.getKey(self.configPath)
+ except:
+ oldValue = None
if oldValue is not None and oldValue != defaultValue:
configfile.setKey(self.configPath, self.datatoFile(self.controlType, self.value), True)