mirror of
https://github.com/AsahiLinux/m1n1
synced 2024-11-22 14:43:08 +00:00
adt.py: raise AttributeError in ADTNode._getattr__()
Signed-off-by: Janne Grunau <j@jannau.net>
This commit is contained in:
parent
2aa41192ed
commit
07314994ed
1 changed files with 3 additions and 1 deletions
|
@ -184,7 +184,9 @@ class ADTNode:
|
|||
|
||||
def __getattr__(self, attr):
|
||||
attr = attr.replace("_", "-")
|
||||
return self._properties[attr]
|
||||
if attr in self._properties:
|
||||
return self._properties[attr]
|
||||
raise AttributeError(attr)
|
||||
|
||||
def __setattr__(self, attr, value):
|
||||
if attr[0] == "_":
|
||||
|
|
Loading…
Reference in a new issue