Skip to content

Commit

Permalink
Setting the catalog name to prevent issues when there are retests
Browse files Browse the repository at this point in the history
  • Loading branch information
travjenkins committed Nov 14, 2023
1 parent 522358d commit 5154753
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/components/capture/useDiscoverCapture.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import {
useEditorStore_isSaving,
useEditorStore_persistedDraftId,
useEditorStore_resetState,
useEditorStore_setCatalogName,
} from 'components/editor/Store/hooks';
import { useEntityWorkflow_Editing } from 'context/Workflow';
import useEntityNameSuffix from 'hooks/useEntityNameSuffix';
Expand Down Expand Up @@ -39,6 +40,7 @@ function useDiscoverCapture(
const persistedDraftId = useEditorStore_persistedDraftId();
const isSaving = useEditorStore_isSaving();
const resetEditorState = useEditorStore_resetState();
const setCatalogName = useEditorStore_setCatalogName();

// Form State Store
const formActive = useFormStateStore_isActive();
Expand Down Expand Up @@ -87,6 +89,7 @@ function useDiscoverCapture(
return false;
}
resetEditorState(true);
setCatalogName(processedEntityName);

const encryptedEndpointConfig = await configEncrypt(
serverUpdateRequired
Expand Down Expand Up @@ -141,6 +144,7 @@ function useDiscoverCapture(
resourceConfigHasErrors,
serverEndpointConfigData,
serverUpdateRequired,
setCatalogName,
setFormState,
startDiscovery,
updateFormStatus,
Expand Down

0 comments on commit 5154753

Please sign in to comment.