From e8b3ffd155b6ef8d88ed32f66feeba5c54e70644 Mon Sep 17 00:00:00 2001 From: Andreu Botella Date: Thu, 7 Oct 2021 19:39:33 +0200 Subject: fix(runtime): Getting `navigator.hardwareConcurrency` on workers shouldn't throw (#12354) --- runtime/js/99_main.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'runtime/js') diff --git a/runtime/js/99_main.js b/runtime/js/99_main.js index 152430a76..4f21655d6 100644 --- a/runtime/js/99_main.js +++ b/runtime/js/99_main.js @@ -348,7 +348,7 @@ delete Object.prototype.__proto__; configurable: true, enumerable: true, get() { - webidl.assertBranded(this, Navigator); + webidl.assertBranded(this, WorkerNavigator); return numCpus; }, }, -- cgit v1.2.3