Skip to content

Commit 59adaf6

Browse files
Ignore un-supported events that backend services might send (#991)
E.g., messages from Yandex metrics
1 parent 3bc3f12 commit 59adaf6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/backend.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,7 @@ var _ = Mavo.Backend = class Backend extends EventTarget {
193193
}
194194

195195
addEventListener("message", evt => {
196-
if (evt.source === this.authPopup) {
196+
if (evt.source === this.authPopup && evt.data.backend) {
197197
if (evt.data.backend == this.id) {
198198
this.accessToken = localStorage[`mavo:${id}token`] = evt.data.token;
199199
}

0 commit comments

Comments
 (0)