summaryrefslogtreecommitdiff
path: root/runtime/js/99_main.js
diff options
context:
space:
mode:
authorawait-ovo <13152410380@163.com>2023-08-15 23:04:36 +0800
committerGitHub <noreply@github.com>2023-08-15 17:04:36 +0200
commit41cad2179fb36c2371ab84ce587d3460af64b5fb (patch)
treec4d4f05e660cdcd9cbb74eb10ca37515241ca913 /runtime/js/99_main.js
parentddbb5fdfb034517f200e298c1a5de8aa03b5e5e5 (diff)
fix(runtime): navigator.userAgent in web worker (#20129)
Fixes https://github.com/denoland/deno/issues/20079 --------- Co-authored-by: Bartek IwaƄczuk <biwanczuk@gmail.com>
Diffstat (limited to 'runtime/js/99_main.js')
-rw-r--r--runtime/js/99_main.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/runtime/js/99_main.js b/runtime/js/99_main.js
index dc6839646..c8fdabc25 100644
--- a/runtime/js/99_main.js
+++ b/runtime/js/99_main.js
@@ -567,7 +567,7 @@ function bootstrapWorkerRuntime(
10: pid,
11: target,
12: v8Version,
- // 13: userAgent,
+ 13: userAgent,
// 14: inspectFlag,
15: enableTestingFeaturesFlag,
} = runtimeOptions;
@@ -633,6 +633,7 @@ function bootstrapWorkerRuntime(
location.setLocationHref(location_);
setNumCpus(cpuCount);
+ setUserAgent(userAgent);
setLanguage(locale);
globalThis.pollForMessages = pollForMessages;