From 857c1d8e2a5e05c7c8fcf8b714fa536373bb990c Mon Sep 17 00:00:00 2001 From: grafixeyehero Date: Sat, 13 Jun 2020 17:33:56 +0300 Subject: [PATCH] apply suggestion --- src/components/imageOptionsEditor/imageOptionsEditor.js | 4 ++-- src/components/libraryoptionseditor/libraryoptionseditor.js | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/components/imageOptionsEditor/imageOptionsEditor.js b/src/components/imageOptionsEditor/imageOptionsEditor.js index a1e7f71a9..2a3022b0d 100644 --- a/src/components/imageOptionsEditor/imageOptionsEditor.js +++ b/src/components/imageOptionsEditor/imageOptionsEditor.js @@ -92,8 +92,8 @@ import 'emby-input'; export class editor { constructor() { this.show = (itemType, options, availableOptions) => { - return new Promise((resolve) => { - import('text!./components/imageOptionsEditor/imageOptionsEditor.template.html').then(({default: template}) => { + return import('text!./components/imageOptionsEditor/imageOptionsEditor.template.html').then(({default: template}) => { + return new Promise((resolve) => { const dlg = dialogHelper.createDialog({ size: 'small', removeOnClose: true, diff --git a/src/components/libraryoptionseditor/libraryoptionseditor.js b/src/components/libraryoptionseditor/libraryoptionseditor.js index 6a5f4f6e9..8b365e51a 100644 --- a/src/components/libraryoptionseditor/libraryoptionseditor.js +++ b/src/components/libraryoptionseditor/libraryoptionseditor.js @@ -364,8 +364,8 @@ import 'emby-input'; currentAvailableOptions = null; const isNewLibrary = null === libraryOptions; isNewLibrary && parent.classList.add('newlibrary'); - return new Promise((resolve) => { - import('text!./libraryoptionseditor.template.html').then(({default: template}) => { + return import('text!./libraryoptionseditor.template.html').then(({default: template}) => { + return new Promise((resolve) => { parent.innerHTML = globalize.translateDocument(template); populateRefreshInterval(parent.querySelector('#selectAutoRefreshInterval')); const promises = [populateLanguages(parent), populateCountries(parent.querySelector('#selectCountry'))];