Skip to content

Commit

Permalink
fix: issue link error toast alert (#5068)
Browse files Browse the repository at this point in the history
  • Loading branch information
anmolsinghbhatia authored Jul 8, 2024
1 parent 1cd55cd commit 4e815c0
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@ export const useLinkOperations = (workspaceSlug: string, projectId: string, issu
type: TOAST_TYPE.SUCCESS,
title: "Link created",
});
} catch (error) {
} catch (error: any) {
setToast({
message: "The link could not be created",
message: error?.data?.error ?? "The link could not be created",
type: TOAST_TYPE.ERROR,
title: "Link not created",
});
Expand Down
4 changes: 2 additions & 2 deletions web/core/components/issues/issue-detail/links/root.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,9 @@ export const IssueLinkRoot: FC<TIssueLinkRoot> = (props) => {
title: "Link created",
});
toggleIssueLinkModal(false);
} catch (error) {
} catch (error: any) {
setToast({
message: "The link could not be created",
message: error?.data?.error ?? "The link could not be created",
type: TOAST_TYPE.ERROR,
title: "Link not created",
});
Expand Down

0 comments on commit 4e815c0

Please sign in to comment.