finish the upload part