|
@@ -116,12 +116,18 @@ export function showNotification(props: INotificationProps = {}, type?: string)
|
116
|
116
|
const { disabledNotifications = [], notifications, notificationTimeouts } = getState()['features/base/config'];
|
117
|
117
|
const enabledFlag = getFeatureFlag(getState(), NOTIFICATIONS_ENABLED, true);
|
118
|
118
|
|
|
119
|
+ const { descriptionKey, titleKey } = props;
|
|
120
|
+
|
119
|
121
|
const shouldDisplay = enabledFlag
|
120
|
|
- && !(disabledNotifications.includes(props.descriptionKey ?? '')
|
121
|
|
- || disabledNotifications.includes(props.titleKey ?? ''))
|
|
122
|
+ && !(disabledNotifications.includes(descriptionKey ?? '')
|
|
123
|
+ || disabledNotifications.includes(titleKey ?? ''))
|
122
|
124
|
&& (!notifications
|
123
|
|
- || notifications.includes(props.descriptionKey ?? '')
|
124
|
|
- || notifications.includes(props.titleKey ?? ''));
|
|
125
|
+ || notifications.includes(descriptionKey ?? '')
|
|
126
|
+ || notifications.includes(titleKey ?? ''));
|
|
127
|
+
|
|
128
|
+ if (typeof APP !== 'undefined') {
|
|
129
|
+ APP.API.notifyNotificationTriggered(titleKey, descriptionKey);
|
|
130
|
+ }
|
125
|
131
|
|
126
|
132
|
if (shouldDisplay) {
|
127
|
133
|
return dispatch({
|