mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
prevent the use of confusing globals
This commit is contained in:
parent
fd102348ce
commit
6159eca8f8
18 changed files with 44 additions and 34 deletions
|
@ -85,9 +85,9 @@ import 'scrollStyles';
|
|||
}
|
||||
|
||||
if (!self.closedByBack && isHistoryEnabled(dlg)) {
|
||||
const state = history.state || {};
|
||||
const state = window.history.state || {};
|
||||
if (state.dialogId === hash) {
|
||||
history.back();
|
||||
window.history.back();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -213,7 +213,7 @@ import 'scrollStyles';
|
|||
export function close(dlg) {
|
||||
if (isOpened(dlg)) {
|
||||
if (isHistoryEnabled(dlg)) {
|
||||
history.back();
|
||||
window.history.back();
|
||||
} else {
|
||||
closeDialog(dlg);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue