Unverified Commit 6caecdfe authored by Marvin Meiers's avatar Marvin Meiers
Browse files

symphony/utils: use __qualname__ to store object type in toJSON

Use __qualname__ instead of __name__, since __qualname__ also works with
nested classes.
parent ea551f0e
......@@ -38,7 +38,7 @@ class IdObj(abc.ABC):
def toJSON(self):
json_obj = {}
json_obj["type"] = self.__class__.__name__
json_obj["type"] = self.__class__.__qualname__
json_obj["module"] = self.__class__.__module__
json_obj["id"] = self._id
return json_obj
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment