await to connect all sockets after register events

This commit is contained in:
SrGooglo 2025-03-25 23:03:05 +00:00
parent cc40fc7fcd
commit 0d9908a90f

View File

@ -18,15 +18,19 @@ export default class NotificationCore extends Core {
},
}
onRuntimeEvents = {
"wsmanager:all:connected": () => {
this.ctx.cores
.get("api")
.registerSocketListeners(this.listenSockets)
},
}
public = {
new: this.new,
close: this.close,
}
async onInitialize() {
this.ctx.cores.get("api").registerSocketListeners(this.listenSockets)
}
async new(notification) {
NotificationUI.notify(notification)
NotificationFeedback.feedback(notification)