Update socket status more eagerly

This commit is contained in:
Fedor Indutny 2021-09-16 13:18:42 -07:00 committed by GitHub
parent 3cf6ea882b
commit f937eba94e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 20 additions and 3 deletions

View file

@ -1093,6 +1093,10 @@ export function initialize({
proxyUrl,
});
socketManager.on('statusChange', () => {
window.Whisper.events.trigger('socketStatusChange');
});
socketManager.on('authError', () => {
window.Whisper.events.trigger('unlinkAndDisconnect');
});