Skip to content

Commit

Permalink
syntax: make the ValueError exception catching py2/3 aware
Browse files Browse the repository at this point in the history
  • Loading branch information
herrnst committed Jun 6, 2018
1 parent 335bcb6 commit 36775bc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion resources/lib/lcdbase.py
Original file line number Diff line number Diff line change
Expand Up @@ -279,7 +279,7 @@ def LoadSkin(self, xmlFile, doReset):
if icontextoffset != None and icontextoffset.text != None:
try:
intoffset = int(icontextoffset.text)
except ValueError, TypeError:
except ValueError as TypeError:
log(LOGERROR, "Value for icontextoffset must be integer (got: %s)" % (icontextoffset.text))
else:
if intoffset <= 0 or intoffset >= self.GetColumns():
Expand Down

0 comments on commit 36775bc

Please sign in to comment.