Minor changes to json parsing