diff --git a/src/utils/notifications.util.js b/src/utils/notifications.util.js index 4966d78bf..589cdee6e 100644 --- a/src/utils/notifications.util.js +++ b/src/utils/notifications.util.js @@ -20,6 +20,7 @@ such restriction. import { setNotification } from '../reducers/notificationReducer' import { getErrorMsg } from 'igz-controls/utils/common.util' +import { FORBIDDEN_ERROR_STATUS_CODE } from 'igz-controls/constants' export const showErrorNotification = (dispatch, error, defaultErrorMsg, customErrorMsg, retryCallback) => { const notificationData = { @@ -29,7 +30,7 @@ export const showErrorNotification = (dispatch, error, defaultErrorMsg, customEr error } - if (retryCallback) { + if (retryCallback && error.response.status !== FORBIDDEN_ERROR_STATUS_CODE) { notificationData.retry = retryCallback }