Skip to content

Commit dce4605

Browse files
committed
Wait for workflowId to be loaded
1 parent 926667b commit dce4605

2 files changed

Lines changed: 6 additions & 2 deletions

File tree

src/components/events/partials/ModalTabsAndPages/EventDetailsWorkflowDetails.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -333,7 +333,9 @@ const OperationsPreview = ({
333333

334334
const loadWorkflowOperations = async () => {
335335
// Fetching workflow operations from server
336-
dispatch(fetchWorkflowOperations({ eventId, workflowId }));
336+
if (workflowId) {
337+
dispatch(fetchWorkflowOperations({ eventId, workflowId }));
338+
}
337339
};
338340

339341
useEffect(() => {

src/components/events/partials/ModalTabsAndPages/EventDetailsWorkflowErrors.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,9 @@ const EventDetailsWorkflowErrors = ({
4747
};
4848

4949
useEffect(() => {
50-
dispatch(fetchWorkflowErrors({ eventId, workflowId })).then();
50+
if (workflowId) {
51+
dispatch(fetchWorkflowErrors({ eventId, workflowId })).then();
52+
}
5153
// eslint-disable-next-line react-hooks/exhaustive-deps
5254
}, []);
5355

0 commit comments

Comments
 (0)