Added check to upload.