Skip to content

Commit cf7676f

Browse files
committed
fix(ses): dont use native hardener which doesnt suppressTrapping
1 parent 7c0edb8 commit cf7676f

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

packages/ses/src/make-hardener.js

+6-7
Original file line numberDiff line numberDiff line change
@@ -130,14 +130,13 @@ const freezeTypedArray = array => {
130130
*/
131131
export const makeHardener = () => {
132132
// TODO Get the native hardener to suppressTrapping at each step,
133-
// rather than freeze. Until then, we cannot use it, which is *expensive*!
134-
// TODO Comment out the following to skip the native hardener.
133+
// rather than freeze. Until then, it is *expensive*!
135134
//
136-
// Use a native hardener if possible.
137-
if (typeof globalThis.harden === 'function') {
138-
const safeHarden = globalThis.harden;
139-
return safeHarden;
140-
}
135+
// // Use a native hardener if possible.
136+
// if (typeof globalThis.harden === 'function') {
137+
// const safeHarden = globalThis.harden;
138+
// return safeHarden;
139+
// }
141140

142141
const hardened = new WeakSet();
143142

0 commit comments

Comments
 (0)