Переглянути джерело

Поправлен баг загрузки шрифтов

Book Pauk 5 роки тому
батько
коміт
8abe71a0fe
1 змінених файлів з 1 додано та 3 видалено
  1. 1 3
      client/components/Reader/TextPage/TextPage.vue

+ 1 - 3
client/components/Reader/TextPage/TextPage.vue

@@ -273,9 +273,7 @@ class TextPage extends Vue {
     async checkLoadedFonts() {
         let loaded = await Promise.all(this.fontList.map(font => document.fonts.check(font)));
         if (loaded.some(r => !r)) {
-            loaded = await Promise.all(this.fontList.map(font => document.fonts.load(font)));
-            if (loaded.some(r => !r.length))
-                throw new Error('some font not loaded');
+            await Promise.all(this.fontList.map(font => document.fonts.load(font)));
         }
     }