From b682b4440f825d7637b2adff71be7f5d02c8e945 Mon Sep 17 00:00:00 2001 From: Camille Barneaud <1693643+gadcam@users.noreply.github.com> Date: Fri, 22 Dec 2017 04:59:03 +0100 Subject: [PATCH] Fix HTML extraction in WebExtensions (#1920) --- src/drivers/webextension/js/content.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/drivers/webextension/js/content.js b/src/drivers/webextension/js/content.js index 49ecba12d..49c21f5e7 100644 --- a/src/drivers/webextension/js/content.js +++ b/src/drivers/webextension/js/content.js @@ -2,7 +2,7 @@ if ( typeof browser !== 'undefined' && typeof document.body !== 'undefined' ) { try { - var html = document.documentElement.outerHTML; + var html = new XMLSerializer().serializeToString(document); if ( html.length > 50000 ) { html = html.substring(0, 25000) + html.substring(html.length - 25000, html.length);