diff --git a/src/components/BulkEditList/BulkEditListResult/BulkEditManualUploadModal/BulkEditManualUploadModal.js b/src/components/BulkEditList/BulkEditListResult/BulkEditManualUploadModal/BulkEditManualUploadModal.js index ee82053e..1912f45e 100644 --- a/src/components/BulkEditList/BulkEditListResult/BulkEditManualUploadModal/BulkEditManualUploadModal.js +++ b/src/components/BulkEditList/BulkEditListResult/BulkEditManualUploadModal/BulkEditManualUploadModal.js @@ -85,9 +85,9 @@ const BulkEditManualUploadModal = ({ setCurrentStep(MANUAL_UPLOAD_STEPS.CONFIRM); }; - const handleCancel = () => { + const handleCancel = (isCancel = true) => { if (controller.current) controller.current.abort(); - if (fileName) bulkOperationDelete({ operationId }); + if (fileName && isCancel) bulkOperationDelete({ operationId }); setCurrentStep(MANUAL_UPLOAD_STEPS.UPLOAD); setFileName(''); @@ -112,7 +112,7 @@ const BulkEditManualUploadModal = ({ } catch { swwCallout(swwErrorMessage); } finally { - handleCancel(); + handleCancel(false); } };