mirror of
https://github.com/Stremio/stremio-web.git
synced 2026-03-11 21:27:05 +00:00
fix(App): core error handling was broken
This commit is contained in:
parent
0463cb109f
commit
4738923be6
1 changed files with 4 additions and 2 deletions
|
|
@ -146,8 +146,10 @@ const App = () => {
|
|||
.catch((e) => console.error(e));
|
||||
}
|
||||
return () => {
|
||||
window.removeEventListener('focus', onWindowFocus);
|
||||
services.core.transport.off('CoreEvent', onCoreEvent);
|
||||
if (services.core.active) {
|
||||
window.removeEventListener('focus', onWindowFocus);
|
||||
services.core.transport.off('CoreEvent', onCoreEvent);
|
||||
}
|
||||
};
|
||||
}, [initialized]);
|
||||
return (
|
||||
|
|
|
|||
Loading…
Reference in a new issue