support old json-c versions without json_object_object_get_ex