add warning when final engine has feature deficit

This commit is contained in:
Móricz Gergő 2024-11-07 00:22:37 +01:00
parent 7a54291d12
commit be40dcb217

View File

@ -227,6 +227,7 @@ async function scrapeURLLoop(
if (result.unsupportedFeatures.size > 0) {
const warning = `The engine used does not support the following features: ${[...result.unsupportedFeatures].join(", ")} -- your scrape may be partial.`;
meta.logger.warn(warning, { engine: result.engine, unsupportedFeatures: result.unsupportedFeatures });
document.warning = document.warning !== undefined ? document.warning + " " + warning : warning;
}