[transit] Change timetable field state from obligatory to optional.

This commit is contained in:
Olga Khlopkova 2020-10-02 15:28:34 +03:00 committed by Anatoliy V. Tomilov
parent a47c82a04b
commit 324eb02e87

View file

@ -163,7 +163,10 @@ std::vector<m2::PointD> GetPointsFromJson(json_t * obj)
TimeTable GetTimeTableFromJson(json_t * obj)
{
json_t * arr = base::GetJSONObligatoryField(obj, "timetable");
json_t * arr = base::GetJSONOptionalField(obj, "timetable");
if (!arr)
return TimeTable{};
CHECK(json_is_array(arr), ());
TimeTable timetable;