From b11c5533e83cea04545fb4fcbe865660353556ff Mon Sep 17 00:00:00 2001 From: Zhang Zhi Date: Mon, 25 Jan 2021 09:27:29 +0800 Subject: [PATCH] Update security.md (#27449) --- docs/tutorial/security.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/tutorial/security.md b/docs/tutorial/security.md index f2708086cf0b..4667b26e647a 100644 --- a/docs/tutorial/security.md +++ b/docs/tutorial/security.md @@ -758,7 +758,7 @@ possible through the modules you allow past the filter. const readOnlyFsProxy = require(/* ... */) // exposes only file read functionality const allowedModules = new Set(['crypto']) -const proxiedModules = new Map(['fs', readOnlyFsProxy]) +const proxiedModules = new Map([['fs', readOnlyFsProxy]]) const allowedElectronModules = new Set(['shell']) const allowedGlobals = new Set()