diff --git a/web/src/elements/PageHeader.ts b/web/src/elements/PageHeader.ts index 6583625c6..02411c852 100644 --- a/web/src/elements/PageHeader.ts +++ b/web/src/elements/PageHeader.ts @@ -17,8 +17,8 @@ import { me } from "../api/Users"; import { EVENT_API_DRAWER_TOGGLE, EVENT_NOTIFICATION_DRAWER_TOGGLE, - EVENT_REFRESH, EVENT_SIDEBAR_TOGGLE, + EVENT_WS_MESSAGE, TITLE_DEFAULT, } from "../constants"; @@ -97,7 +97,7 @@ export class PageHeader extends LitElement { constructor() { super(); - window.addEventListener(EVENT_REFRESH, () => { + window.addEventListener(EVENT_WS_MESSAGE, () => { this.firstUpdated(); }); } diff --git a/web/src/interfaces/UserInterface.ts b/web/src/interfaces/UserInterface.ts index 3f52530da..bd0b8d583 100644 --- a/web/src/interfaces/UserInterface.ts +++ b/web/src/interfaces/UserInterface.ts @@ -25,7 +25,7 @@ import { WebsocketClient } from "../common/ws"; import { EVENT_API_DRAWER_TOGGLE, EVENT_NOTIFICATION_DRAWER_TOGGLE, - EVENT_REFRESH, + EVENT_WS_MESSAGE, } from "../constants"; import "../elements/messages/MessageContainer"; import "../elements/messages/MessageContainer"; @@ -115,7 +115,7 @@ export class UserInterface extends LitElement { apiDrawerOpen: this.apiDrawerOpen, }); }); - window.addEventListener(EVENT_REFRESH, () => { + window.addEventListener(EVENT_WS_MESSAGE, () => { this.firstUpdated(); }); tenant().then((tenant) => (this.tenant = tenant));