added support for JSON objects