mirror of
https://github.com/evennia/evennia.git
synced 2026-03-16 21:06:30 +01:00
makes attributeproperty "object-aware"
This commit is contained in:
parent
0c62046224
commit
614a9ab048
1 changed files with 2 additions and 2 deletions
|
|
@ -224,7 +224,7 @@ class AttributeProperty:
|
|||
category=self._category,
|
||||
strattr=self._strattr,
|
||||
raise_exception=self._autocreate,
|
||||
))
|
||||
), instance)
|
||||
except AttributeError:
|
||||
if self._autocreate:
|
||||
# attribute didn't exist and autocreate is set
|
||||
|
|
@ -274,7 +274,7 @@ class AttributeProperty:
|
|||
"""
|
||||
return value
|
||||
|
||||
def at_get(self, value):
|
||||
def at_get(self, value, obj):
|
||||
"""
|
||||
The value returned from the Attribute is passed through this method. It can be used
|
||||
to react to the retrieval or modify the result in some way.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue