iOS backgrounding wait for upload