Changed how the json file is opened.