bug fixes wrt uploading