Gildas преди 7 години
родител
ревизия
eddad92e35
променени са 1 файла, в които са добавени 2 реда и са изтрити 2 реда
  1. 2 2
      lib/single-file/css-fonts-minifier.js

+ 2 - 2
lib/single-file/css-fonts-minifier.js

@@ -227,10 +227,10 @@ this.fontsMinifier = this.fontsMinifier || (() => {
 		const fontTest = (fontSource, format) => fontSource.src != EMPTY_URL_SOURCE && fontSource.format == format;
 		const fontTest = (fontSource, format) => fontSource.src != EMPTY_URL_SOURCE && fontSource.format == format;
 		let woffFontFound = fontSources.find(fontSource => fontTest(fontSource, "woff2-variations"));
 		let woffFontFound = fontSources.find(fontSource => fontTest(fontSource, "woff2-variations"));
 		if (!woffFontFound) {
 		if (!woffFontFound) {
-			woffFontFound = fontSources.find(fontSource => fontTest(fontSource, "woff2"));
+			woffFontFound = fontSources.find(fontSource => fontTest(fontSource, "woff"));
 		}
 		}
 		if (!woffFontFound) {
 		if (!woffFontFound) {
-			woffFontFound = fontSources.find(fontSource => fontTest(fontSource, "woff"));
+			woffFontFound = fontSources.find(fontSource => fontTest(fontSource, "woff2"));
 		}
 		}
 		stats.fonts.processed += fontSources.length;
 		stats.fonts.processed += fontSources.length;
 		stats.fonts.discarded += fontSources.length;
 		stats.fonts.discarded += fontSources.length;