html-get 2.26.10 → 2.26.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/index.js +5 -1
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "html-get",
|
|
3
3
|
"description": "Get the HTML from any website, fine-tuned for correction & speed",
|
|
4
4
|
"homepage": "https://nicedoc.com/microlinkhq/html-get",
|
|
5
|
-
"version": "2.26.
|
|
5
|
+
"version": "2.26.12",
|
|
6
6
|
"types": "index.d.ts",
|
|
7
7
|
"main": "src/index.js",
|
|
8
8
|
"bin": {
|
package/src/index.js
CHANGED
|
@@ -430,7 +430,11 @@ module.exports = PCancelable.fn(
|
|
|
430
430
|
// Same rule as the prerender 4xx fetch fallback: challenge HTML is
|
|
431
431
|
// still a successful page.content(), so only replace a working fetch
|
|
432
432
|
// when the retry is actually usable.
|
|
433
|
-
if (
|
|
433
|
+
if (
|
|
434
|
+
prerenderResult.mode === 'prerender' &&
|
|
435
|
+
prerenderResult.html &&
|
|
436
|
+
prerenderResult.statusCode < 400
|
|
437
|
+
) {
|
|
434
438
|
;({ mode, html, $, ...payload } = prerenderResult)
|
|
435
439
|
shadowDOM = hasShadowDOM($)
|
|
436
440
|
}
|