add support for custom __json__ magic method on serialized objects