Skip to content

Commit f9e10fd

Browse files
aduh95juanarbol
authored andcommitted
lib: define kEnumerableProperty atomically
Signed-off-by: Antoine du Hamel <duhamelantoine1995@gmail.com> PR-URL: #63609 Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Filip Skokan <panva.ip@gmail.com> Reviewed-By: Chengzhong Wu <legendecas@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
1 parent a56b979 commit f9e10fd

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

lib/internal/util.js

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -704,9 +704,10 @@ const lazyDOMException = (message, name) => {
704704

705705
};
706706

707-
const kEnumerableProperty = { __proto__: null };
708-
kEnumerableProperty.enumerable = true;
709-
ObjectFreeze(kEnumerableProperty);
707+
const kEnumerableProperty = ObjectFreeze({
708+
__proto__: null,
709+
enumerable: true,
710+
});
710711

711712
const kEmptyObject = ObjectFreeze({ __proto__: null });
712713

0 commit comments

Comments
 (0)