diff options
Diffstat (limited to 'runtime/js')
-rw-r--r-- | runtime/js/40_fs_events.js | 3 | ||||
-rw-r--r-- | runtime/js/40_process.js | 1 | ||||
-rw-r--r-- | runtime/js/98_global_scope_window.js | 5 | ||||
-rw-r--r-- | runtime/js/98_global_scope_worker.js | 5 | ||||
-rw-r--r-- | runtime/js/99_main.js | 3 |
5 files changed, 16 insertions, 1 deletions
diff --git a/runtime/js/40_fs_events.js b/runtime/js/40_fs_events.js index a0495540c..2140f29eb 100644 --- a/runtime/js/40_fs_events.js +++ b/runtime/js/40_fs_events.js @@ -23,6 +23,7 @@ class FsWatcher { constructor(paths, options) { if (internals.future) { ObjectDefineProperty(this, "rid", { + __proto__: null, enumerable: false, value: undefined, }); @@ -79,7 +80,7 @@ class FsWatcher { function watchFs( paths, - options = { recursive: true }, + options = { __proto__: null, recursive: true }, ) { return new FsWatcher(ArrayIsArray(paths) ? paths : [paths], options); } diff --git a/runtime/js/40_process.js b/runtime/js/40_process.js index 954d8d00b..358805180 100644 --- a/runtime/js/40_process.js +++ b/runtime/js/40_process.js @@ -463,6 +463,7 @@ class Command { spawn() { const options = { + __proto__: null, ...(this.#options ?? {}), stdout: this.#options?.stdout ?? "inherit", stderr: this.#options?.stderr ?? "inherit", diff --git a/runtime/js/98_global_scope_window.js b/runtime/js/98_global_scope_window.js index aa18ed361..27a3d309a 100644 --- a/runtime/js/98_global_scope_window.js +++ b/runtime/js/98_global_scope_window.js @@ -60,6 +60,7 @@ const language = memoizeLazy(() => op_bootstrap_language()); ObjectDefineProperties(Navigator.prototype, { gpu: { + __proto__: null, configurable: true, enumerable: true, get() { @@ -69,6 +70,7 @@ ObjectDefineProperties(Navigator.prototype, { }, }, hardwareConcurrency: { + __proto__: null, configurable: true, enumerable: true, get() { @@ -77,6 +79,7 @@ ObjectDefineProperties(Navigator.prototype, { }, }, userAgent: { + __proto__: null, configurable: true, enumerable: true, get() { @@ -85,6 +88,7 @@ ObjectDefineProperties(Navigator.prototype, { }, }, language: { + __proto__: null, configurable: true, enumerable: true, get() { @@ -93,6 +97,7 @@ ObjectDefineProperties(Navigator.prototype, { }, }, languages: { + __proto__: null, configurable: true, enumerable: true, get() { diff --git a/runtime/js/98_global_scope_worker.js b/runtime/js/98_global_scope_worker.js index 8e292108f..4dc615786 100644 --- a/runtime/js/98_global_scope_worker.js +++ b/runtime/js/98_global_scope_worker.js @@ -58,6 +58,7 @@ const workerNavigator = webidl.createBranded(WorkerNavigator); ObjectDefineProperties(WorkerNavigator.prototype, { gpu: { + __proto__: null, configurable: true, enumerable: true, get() { @@ -67,6 +68,7 @@ ObjectDefineProperties(WorkerNavigator.prototype, { }, }, hardwareConcurrency: { + __proto__: null, configurable: true, enumerable: true, get() { @@ -75,6 +77,7 @@ ObjectDefineProperties(WorkerNavigator.prototype, { }, }, userAgent: { + __proto__: null, configurable: true, enumerable: true, get() { @@ -83,6 +86,7 @@ ObjectDefineProperties(WorkerNavigator.prototype, { }, }, language: { + __proto__: null, configurable: true, enumerable: true, get() { @@ -91,6 +95,7 @@ ObjectDefineProperties(WorkerNavigator.prototype, { }, }, languages: { + __proto__: null, configurable: true, enumerable: true, get() { diff --git a/runtime/js/99_main.js b/runtime/js/99_main.js index d83bfbff1..2d5c96f6a 100644 --- a/runtime/js/99_main.js +++ b/runtime/js/99_main.js @@ -92,12 +92,14 @@ if (Symbol.metadata) { } ObjectDefineProperties(Symbol, { dispose: { + __proto__: null, value: SymbolDispose, enumerable: false, writable: false, configurable: false, }, metadata: { + __proto__: null, value: SymbolMetadata, enumerable: false, writable: false, @@ -533,6 +535,7 @@ ObjectDefineProperties(finalDenoNs, { args: core.propGetterOnly(opArgs), mainModule: core.propGetterOnly(() => op_main_module()), exitCode: { + __proto__: null, get() { return os.getExitCode(); }, |