cleanup of upload dialog