fixing crash on json absence