Update to support subclasses.

This commit is contained in:
Owllex 2022-04-15 08:34:20 -07:00
parent d5c916ecc3
commit 014ae2e6e1
2 changed files with 16 additions and 1 deletions

View file

@ -332,7 +332,7 @@ class TypedObject(SharedMemoryModel):
by fetching them once.
"""
for propkey, prop in self.__class__.__dict__.items():
if isinstance(prop, (AttributeProperty, TagProperty)):
if inherits_from(prop, AttributeProperty) or inherits_from(prop, TagProperty):
try:
getattr(self, propkey)
except Exception: