mirror of
https://github.com/evennia/evennia.git
synced 2026-03-16 21:06:30 +01:00
Default db_strvalue to None if nonexistent
This commit is contained in:
parent
389a212c63
commit
3a093e134c
2 changed files with 3 additions and 3 deletions
|
|
@ -2831,7 +2831,7 @@ class CmdExamine(ObjManipCommand):
|
|||
|
||||
key, category, value = attr.db_key, attr.db_category, attr.value
|
||||
valuetype = ""
|
||||
if value is None and getattr(attr, "strvalue", None) is not None:
|
||||
if value is None and attr.strvalue is not None:
|
||||
value = attr.strvalue
|
||||
valuetype = " |B[strvalue]|n"
|
||||
typ = self._get_attribute_value_type(value)
|
||||
|
|
@ -2850,7 +2850,7 @@ class CmdExamine(ObjManipCommand):
|
|||
|
||||
key, category, value = attr.db_key, attr.db_category, attr.value
|
||||
valuetype = ""
|
||||
if value is None and getattr(attr, "strvalue", None) is not None:
|
||||
if value is None and attr.strvalue is not None:
|
||||
value = attr.strvalue
|
||||
valuetype = " |B[strvalue]|n"
|
||||
typ = self._get_attribute_value_type(value)
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@ class IAttribute:
|
|||
return LockHandler(self)
|
||||
|
||||
key = property(lambda self: self.db_key)
|
||||
strvalue = property(lambda self: self.db_strvalue)
|
||||
strvalue = property(lambda self: getattr(self, 'db_strvalue', None))
|
||||
category = property(lambda self: self.db_category)
|
||||
model = property(lambda self: self.db_model)
|
||||
attrtype = property(lambda self: self.db_attrtype)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue