Explorar o código

expose insertSingleFileComment (fix #702)

Gildas %!s(int64=4) %!d(string=hai) anos
pai
achega
1a2545c7b0

+ 2 - 1
extension/core/bg/config.js

@@ -101,7 +101,8 @@ const DEFAULT_CONFIG = {
 	warnUnsavedPage: true,
 	autoSaveExternalSave: false,
 	insertMetaNoIndex: false,
-	passReferrerOnError: false
+	passReferrerOnError: false,
+	insertSingleFileComment: true
 };
 
 let configStorage;

+ 0 - 1
extension/core/content/content.js

@@ -114,7 +114,6 @@ async function processPage(options) {
 	ui.onStartPage(options);
 	processor = new singlefile.SingleFile(options);
 	const preInitializationPromises = [];
-	options.insertSingleFileComment = true;
 	options.insertCanonicalLink = true;
 	if (!options.saveRawPage) {
 		if (!options.removeFrames && frames && globalThis.frames && globalThis.frames.length) {

+ 0 - 1
lib/single-file/index.js

@@ -71,7 +71,6 @@ async function getPageData(options = {}, initOptions, doc = globalThis.document,
 	}
 	options.doc = doc;
 	options.win = win;
-	options.insertSingleFileComment = true;
 	options.insertCanonicalLink = true;
 	options.onprogress = event => {
 		if (event.type === event.RESOURCES_INITIALIZED && doc && win && options.loadDeferredImages) {