fix #938: check hasActivity in onPostExecute to avoid a npe
move hasActivity()
Merge pull request #940 from wordpress-mobile/issue/938-npe-while-uploading-from-photos-app

fix #938: check hasActivity in onPostExecute to avoid a npe