fix crash on faulty API response
Merge pull request #19 from askmike/patch-6

fix crash on faulty API response