diff --git a/src/Umbraco.Web.UI.Client/src/core/notification/notification.service.ts b/src/Umbraco.Web.UI.Client/src/core/notification/notification.service.ts index f5fca5945e..793944c0d6 100644 --- a/src/Umbraco.Web.UI.Client/src/core/notification/notification.service.ts +++ b/src/Umbraco.Web.UI.Client/src/core/notification/notification.service.ts @@ -1,4 +1,4 @@ -import { BehaviorSubject, Observable } from 'rxjs'; +import { UniqueBehaviorSubject } from '../observable-api/unique-behavior-subject'; import { UmbNotificationHandler } from '.'; export type UmbNotificationData = any; @@ -18,10 +18,8 @@ export interface UmbNotificationOptions { export type UmbNotificationColor = '' | 'default' | 'positive' | 'warning' | 'danger'; export class UmbNotificationService { - private _notifications: BehaviorSubject> = new BehaviorSubject( - >[] - ); - public readonly notifications: Observable> = this._notifications.asObservable(); + private _notifications = new UniqueBehaviorSubject(>[]); + public readonly notifications = this._notifications.asObservable(); /** * @private