[IMP] fields: remove unnecessary code
In `__getattr__`, remove the test on accessing `_attrs`. This situation should never happen, since the attribute `_attrs` is set in method `__init__()`.
This commit is contained in:
parent
4259fe0072
commit
1df3467888
|
@ -350,8 +350,6 @@ class Field(object):
|
|||
|
||||
def __getattr__(self, name):
|
||||
""" Access non-slot field attribute. """
|
||||
if name == '_attrs':
|
||||
raise AttributeError(name)
|
||||
try:
|
||||
return self._attrs[name]
|
||||
except KeyError:
|
||||
|
|
Loading…
Reference in New Issue