mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
Merge pull request #4138 from dmitrylyzo/fix-history-back-promise
Fix resolving of the history back Promise
This commit is contained in:
commit
d5c4482714
1 changed files with 5 additions and 1 deletions
|
@ -63,7 +63,11 @@ class AppRouter {
|
||||||
if (this.promiseShow) await this.promiseShow;
|
if (this.promiseShow) await this.promiseShow;
|
||||||
|
|
||||||
this.promiseShow = new Promise((resolve) => {
|
this.promiseShow = new Promise((resolve) => {
|
||||||
this.resolveOnNextShow = resolve;
|
const unlisten = history.listen(() => {
|
||||||
|
unlisten();
|
||||||
|
this.promiseShow = null;
|
||||||
|
resolve();
|
||||||
|
});
|
||||||
history.back();
|
history.back();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue