Issue #699, upload not getting zipped. The code would not zip on http
error, this is changed.
cursor was not checking cursor.getCount() > 0 before working with it,
could cause crash
Merge pull request #702 from garvankeeley/issue699

Issue #699, upload not getting zipped.
Merge pull request #703 from garvankeeley/issue696

cursor was not checking cursor.getCount() > 0 before working with it,