updated the json methods