Skip to content

Commit 87058a2

Browse files
committed
Updated the regex
1 parent 67339fb commit 87058a2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

packages/event-handler/src/rest/constants.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,8 +94,8 @@ export const UNSAFE_CHARS = '%<> \\[\\]{}|^';
9494
export const COMPRESSIBLE_CONTENT_TYPE_REGEX = {
9595
COMMON: /^\s*application\/json(?:[;\s]|$)/i,
9696
OCCASIONAL:
97-
/^\s*(?:text\/(?!event-stream(?:[;\s]|$))[^;\s]+|application\/(?:xml|javascript|xml-dtd|ecmascript|dart|postscript|rtf|tar|toml|x-www-form-urlencoded)|[^;\s]+?\+(?:json|text|xml|yaml))(?:[;\s]|$)/i,
98-
RARE: /^\s*(?:application\/(?:vnd\.dart|vnd\.ms-fontobject|vnd\.ms-opentype|wasm|x-httpd-php|x-javascript|x-ns-proxy-autoconfig|x-sh|x-tar|x-virtualbox-hdd|x-virtualbox-ova|x-virtualbox-ovf|x-virtualbox-vbox|x-virtualbox-vdi|x-virtualbox-vhd|x-virtualbox-vmdk)|font\/(?:otf|ttf)|image\/(?:bmp|vnd\.adobe\.photoshop|vnd\.microsoft\.icon|vnd\.ms-dds|x-icon|x-ms-bmp)|message\/rfc822|model\/gltf-binary|x-shader\/x-fragment|x-shader\/x-vertex)(?:[;\s]|$)/i,
97+
/^\s*(?:text\/(?!event-stream(?:[;\s]|$))[^;\s]+|application\/(?:xml|javascript)|[^;\s]+?\+(?:json|text|xml|yaml))(?:[;\s]|$)/i,
98+
RARE: /^\s*(?:application\/(?:xml-dtd|ecmascript|dart|postscript|rtf|tar|toml|vnd\.dart|vnd\.ms-fontobject|vnd\.ms-opentype|wasm|x-httpd-php|x-javascript|x-ns-proxy-autoconfig|x-sh|x-tar|x-virtualbox-hdd|x-virtualbox-ova|x-virtualbox-ovf|x-virtualbox-vbox|x-virtualbox-vdi|x-virtualbox-vhd|x-virtualbox-vmdk|x-www-form-urlencoded)|font\/(?:otf|ttf)|image\/(?:bmp|vnd\.adobe\.photoshop|vnd\.microsoft\.icon|vnd\.ms-dds|x-icon|x-ms-bmp)|message\/rfc822|model\/gltf-binary|x-shader\/x-fragment|x-shader\/x-vertex)(?:[;\s]|$)/i,
9999
};
100100

101101
export const CACHE_CONTROL_NO_TRANSFORM_REGEX =

0 commit comments

Comments
 (0)