Update readJSON function.