Преглед изворни кода

remove comments before processing the CSS file

Gildas пре 7 година
родитељ
комит
461cde1854
1 измењених фајлова са 1 додато и 1 уклоњено
  1. 1 1
      lib/single-file/single-file-core.js

+ 1 - 1
lib/single-file/single-file-core.js

@@ -1187,10 +1187,10 @@ this.SingleFileCore = this.SingleFileCore || (() => {
 			if (resourceURL && resourceURL != baseURI && resourceURL != ABOUT_BLANK_URI) {
 				const downloadOptions = { asDataURI: false, maxResourceSize: options.maxResourceSize, maxResourceSizeEnabled: options.maxResourceSizeEnabled, charSet: options.charSet };
 				let stylesheetContent = await Download.getContent(resourceURL, downloadOptions);
-				stylesheetContent = await DomProcessorHelper.resolveImportURLs(stylesheetContent, resourceURL, options);
 				if (options.compressCSS) {
 					stylesheetContent = DOM.compressCSS(DomUtil.removeCssComments(stylesheetContent));
 				}
+				stylesheetContent = await DomProcessorHelper.resolveImportURLs(stylesheetContent, resourceURL, options);
 				return stylesheetContent;
 			}
 		}