From c46dd712dd14888aa83c4567d07aeede7ce11b1c Mon Sep 17 00:00:00 2001 From: Ian Bolton Date: Thu, 20 Jul 2023 15:20:12 -0400 Subject: [PATCH] :bug: Fix missing notification for adding tracker (#1176) - Resolves https://issues.redhat.com/browse/MTA-973?filter=-1 Signed-off-by: ibolton336 --- client/src/app/pages/external/jira/tracker-form.tsx | 4 ++-- client/src/app/queries/trackers.ts | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/client/src/app/pages/external/jira/tracker-form.tsx b/client/src/app/pages/external/jira/tracker-form.tsx index aae23807b..db090f22a 100644 --- a/client/src/app/pages/external/jira/tracker-form.tsx +++ b/client/src/app/pages/external/jira/tracker-form.tsx @@ -78,7 +78,7 @@ export const TrackerForm: React.FC = ({ const onCreateTrackerSuccess = (_: AxiosResponse) => pushNotification({ title: t("toastr.success.save", { - type: t("terms.instance").toLocaleLowerCase(), + type: t("terms.instance"), }), variant: "success", }); @@ -95,7 +95,7 @@ export const TrackerForm: React.FC = ({ const onUpdateTrackerSuccess = (_: AxiosResponse) => pushNotification({ title: t("toastr.success.save", { - type: t("terms.instance").toLocaleLowerCase(), + type: t("terms.instance"), }), variant: "success", }); diff --git a/client/src/app/queries/trackers.ts b/client/src/app/queries/trackers.ts index 73ad9c5ec..a0a05cffb 100644 --- a/client/src/app/queries/trackers.ts +++ b/client/src/app/queries/trackers.ts @@ -40,8 +40,8 @@ export const useCreateTrackerMutation = ( const queryClient = useQueryClient(); return useMutation({ mutationFn: createTracker, - onSuccess: () => { - onSuccess; + onSuccess: (res) => { + onSuccess(res); queryClient.invalidateQueries([TrackersQueryKey]); }, onError: onError,