Updated json parsing to properly handle optional struct fields