Await promise

This commit is contained in:
garrettmills
2020-05-25 17:27:29 -05:00
parent af01cd0f5d
commit a1a70e0548

View File

@@ -27,7 +27,7 @@ class MessageService {
this.listener = setInterval(() => this._listener_tick(), this.listener_interval)
window.addEventListener('beforeunload', () => this.stop_listener())
try {
this._listener_tick()
await this._listener_tick()
} catch (e) {
this.stop_listener()
}