X-Git-Url: https://git.arvados.org/arvados-workbench2.git/blobdiff_plain/fa9b3ce44a3a9315207852d1f182000a6166f9e9..2e21cc7eeaecd3282d464c096549486b391c9461:/src/store/processes/process-update-actions.ts diff --git a/src/store/processes/process-update-actions.ts b/src/store/processes/process-update-actions.ts index f8d78bc6..c7fd1b55 100644 --- a/src/store/processes/process-update-actions.ts +++ b/src/store/processes/process-update-actions.ts @@ -4,13 +4,13 @@ import { Dispatch } from "redux"; import { FormErrors, initialize, startSubmit, stopSubmit } from 'redux-form'; -import { RootState } from "~/store/store"; -import { dialogActions } from "~/store/dialog/dialog-actions"; -import { getCommonResourceServiceError, CommonResourceServiceError } from "~/services/common-service/common-resource-service"; -import { ServiceRepository } from "~/services/services"; -import { getProcess } from '~/store/processes/process'; -import { projectPanelActions } from '~/store/project-panel/project-panel-action'; -import {snackbarActions, SnackbarKind} from '~/store/snackbar/snackbar-actions'; +import { RootState } from "store/store"; +import { dialogActions } from "store/dialog/dialog-actions"; +import { getCommonResourceServiceError, CommonResourceServiceError } from "services/common-service/common-resource-service"; +import { ServiceRepository } from "services/services"; +import { getProcess } from 'store/processes/process'; +import { projectPanelActions } from 'store/project-panel/project-panel-action'; +import {snackbarActions, SnackbarKind} from 'store/snackbar/snackbar-actions'; export interface ProcessUpdateFormDialogData { uuid: string; @@ -41,7 +41,7 @@ export const updateProcess = (resource: ProcessUpdateFormDialogData) => return updatedProcess; } catch (e) { const error = getCommonResourceServiceError(e); - if (error === CommonResourceServiceError.UNIQUE_VIOLATION) { + if (error === CommonResourceServiceError.UNIQUE_NAME_VIOLATION) { dispatch(stopSubmit(PROCESS_UPDATE_FORM_NAME, { name: 'Process with the same name already exists.' } as FormErrors)); } else { dispatch(dialogActions.CLOSE_DIALOG({ id: PROCESS_UPDATE_FORM_NAME }));