mirror of https://github.com/dirtbags/moth.git
Handling exceptions appropriately
This commit is contained in:
parent
f650f20aa7
commit
24f2b6cd67
|
@ -85,7 +85,7 @@ class PuzzleSuccess(dict):
|
||||||
if attr in self.valid_fields:
|
if attr in self.valid_fields:
|
||||||
self[attr] = value
|
self[attr] = value
|
||||||
else:
|
else:
|
||||||
raise AttributeError()
|
raise AttributeError("'%s' object has no attribute '%s'" % (type(self).__name__, attr))
|
||||||
|
|
||||||
|
|
||||||
class Puzzle:
|
class Puzzle:
|
||||||
|
|
Loading…
Reference in New Issue