Gildas 7 vuotta sitten
vanhempi
sitoutus
6b680d9b0d
1 muutettua tiedostoa jossa 2 lisäystä ja 2 poistoa
  1. 2 2
      lib/single-file/single-file-core.js

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

@@ -318,7 +318,7 @@ this.SingleFileCore = this.SingleFileCore || (() => {
 			DOM.postProcessDoc(this.doc, this.options);
 			const url = new URL(this.baseURI);
 			if (this.options.insertSingleFileComment) {
-				let infobarContent = (this.options.infobarContent || "").replace(/\\n/g, "\n").replace(/\\t/g, "\t");
+				const infobarContent = (this.options.infobarContent || "").replace(/\\n/g, "\n").replace(/\\t/g, "\t");
 				const commentNode = this.doc.createComment("\n Page saved with SingleFile" +
 					" \n url: " + this.options.url +
 					" \n saved date: " + new Date() +
@@ -1190,7 +1190,7 @@ this.SingleFileCore = this.SingleFileCore || (() => {
 							const { content } = await batchRequest.addURL(resourceURL, false);
 							const DOMParser = DOM.getParser();
 							if (DOMParser) {
-								let svgDoc = new DOMParser().parseFromString(content, "image/svg+xml");
+								const svgDoc = new DOMParser().parseFromString(content, "image/svg+xml");
 								const hashMatch = originalResourceURL.match(REGEXP_URL_HASH);
 								if (hashMatch && hashMatch[0]) {
 									const symbolElement = svgDoc.querySelector(hashMatch[0]);