|
|
@ -18,7 +18,9 @@ function monkeyPatchEnd(res) {
|
|
|
|
let prefix;
|
|
|
|
let prefix;
|
|
|
|
|
|
|
|
|
|
|
|
if (originalChunk == null || typeof originalChunk === "string" || Buffer.isBuffer(originalChunk)) {
|
|
|
|
if (originalChunk == null || typeof originalChunk === "string" || Buffer.isBuffer(originalChunk)) {
|
|
|
|
if (res.getHeader("content-type").startsWith("text/html")) {
|
|
|
|
let typeHeader = res.getHeader("content-type");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (typeHeader != null && typeHeader.startsWith("text/html")) {
|
|
|
|
let contentLength = res.getHeader("content-length");
|
|
|
|
let contentLength = res.getHeader("content-length");
|
|
|
|
|
|
|
|
|
|
|
|
if (contentLength != null) {
|
|
|
|
if (contentLength != null) {
|
|
|
|