ese-unibe-ch / ese2013-team5

3 stars 4 forks source link

App crashes when the server returns no data (e.g. monday and no new menus yet) #45

Closed exside closed 10 years ago

exside commented 10 years ago

The problem lies in the webservice which tries to convertStreamToJSON() and fails there. @NicolasKessler: can you fix this?

exside commented 10 years ago

to keep the app working i just put a -1 directly in the code for the week calculation, so now the menus for last week are shown until we fix that...I can also adapt the API if you need something better than an empty json array...

PlekszyGladz commented 10 years ago

I guess this should not be very hard to correct from my point of view... I'll tend to it tomorrow

PlekszyGladz commented 10 years ago

Now when the download fails for any reason the app tries to load the latest cached data from the database insted. We need to handle the case when the download and the local load fail now

exside commented 10 years ago

the data from the API will never be empty, normally, but even this case would be handled by the new implementation, as far as I can see...