FIX: missing appEvents param for onNotification (#27180)

The `onNotification` signature is:

```
onNotification(data, siteSettings, user, appEvents)
```

And we were not passing `appEvents`.

Also explicitly inject `currentUser` in `chat-notification-manager` service.
This commit is contained in:
Joffrey JAFFEUX 2024-05-24 18:39:54 +02:00 committed by GitHub
parent bc089dc52b
commit 14b8894ddb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -11,6 +11,8 @@ export default class ChatNotificationManager extends Service {
@service presence;
@service chat;
@service chatStateManager;
@service currentUser;
@service appEvents;
_subscribedToCore = true;
_subscribedToChat = false;
@ -143,7 +145,12 @@ export default class ChatNotificationManager extends Service {
@bind
onMessage(data) {
return onNotification(data, this.siteSettings, this.currentUser);
return onNotification(
data,
this.siteSettings,
this.currentUser,
this.appEvents
);
}
_shouldRun() {