Skip to content

Commit

Permalink
[processing] handle string settings from previous install (followup 0…
Browse files Browse the repository at this point in the history
  • Loading branch information
alexbruy committed Jan 13, 2017
1 parent f01b2f0 commit daf65d8
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions python/plugins/processing/core/ProcessingConfig.py
Original file line number Diff line number Diff line change
Expand Up @@ -232,10 +232,7 @@ def getSetting(name):
v = None
except:
pass
if ProcessingConfig.settings[name].valuetype == Setting.SELECTION:
return ProcessingConfig.settings[name].options.index(v)
else:
return v
return v
else:
return None

Expand Down Expand Up @@ -328,7 +325,10 @@ def read(self, qsettings=QSettings()):
value = str(value).lower() == str(True).lower()

if self.valuetype == self.SELECTION:
self.value = self.options[int(value)]
try:
self.value = self.options[int(value)]
except:
self.value = self.options[0]
else:
self.value = value

Expand Down

0 comments on commit daf65d8

Please sign in to comment.