Raise AttributeError.

Makes hasattr work correctly.
This commit is contained in:
Tim 'mithro' Ansell 2016-12-23 11:14:18 +01:00
parent 688c66dda1
commit b81839bf1a
1 changed files with 1 additions and 1 deletions

View File

@ -14,7 +14,7 @@ class CSRElements:
return self.__dict__[attr]
except KeyError:
pass
raise KeyError("No such element " + attr)
raise AttributeError("No such element " + attr)
class CSRRegister: