Skip to content

Commit

Permalink
Merge pull request #177 from custom-components/ludeeus-patch-1
Browse files Browse the repository at this point in the history
Return the super class directly
  • Loading branch information
isabellaalstrom authored Jan 26, 2022
2 parents e2e0442 + 4ad4cd5 commit 0a00bb2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion custom_components/grocy/json_encode.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,6 @@ def default(self, o: Any) -> Any:
return o.as_dict()

try:
json.JSONEncoder.default(self, o)
return json.JSONEncoder.default(self, o)
except TypeError:
return {"__type": str(type(o)), "repr": repr(o), "str": str(o)}

0 comments on commit 0a00bb2

Please sign in to comment.