Fix crash on upload of non-camera files