diff options
author | Mark Ladyshau <47859603+mrkldshv@users.noreply.github.com> | 2022-06-19 23:33:24 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-06-19 23:33:24 +0200 |
commit | 60869c2598321386f57e55537e8c99ed011fbb95 (patch) | |
tree | a318d137c9b69da940652f0b5926aa32dcf8cb5d /ext/fetch/26_fetch.js | |
parent | 9f1f76f0b0fc71fc57a885f37c5bcabfd1de4b82 (diff) |
fix(ext/fetch): add `accept-language` default header to fetch (#14882)
Diffstat (limited to 'ext/fetch/26_fetch.js')
-rw-r--r-- | ext/fetch/26_fetch.js | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/ext/fetch/26_fetch.js b/ext/fetch/26_fetch.js index 7ef9bdaf7..9a4916e21 100644 --- a/ext/fetch/26_fetch.js +++ b/ext/fetch/26_fetch.js @@ -452,6 +452,10 @@ ArrayPrototypePush(request.headerList, ["Accept", "*/*"]); } + if (!requestObject.headers.has("Accept-Language")) { + ArrayPrototypePush(request.headerList, ["Accept-Language", "*"]); + } + // 12. opPromise = PromisePrototypeCatch( PromisePrototypeThen( |