Skip to content

Commit d90a5e0

Browse files
fhinkeladdaleax
authored andcommitted
src: replace deprecated ForceSet() method
ForceSet() is marked to be deprecated. Replacing it with DefineOwnProperty(). PR-URL: #14450 Reviewed-By: James M Snell <[email protected]> Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Tobias Nießen <[email protected]>
1 parent 92b0555 commit d90a5e0

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/async-wrap.cc

+4-4
Original file line numberDiff line numberDiff line change
@@ -512,10 +512,10 @@ void AsyncWrap::Initialize(Local<Object> target,
512512
static_cast<v8::PropertyAttribute>(v8::ReadOnly | v8::DontDelete);
513513

514514
#define FORCE_SET_TARGET_FIELD(obj, str, field) \
515-
(obj)->ForceSet(context, \
516-
FIXED_ONE_BYTE_STRING(isolate, str), \
517-
field, \
518-
ReadOnlyDontDelete).FromJust()
515+
(obj)->DefineOwnProperty(context, \
516+
FIXED_ONE_BYTE_STRING(isolate, str), \
517+
field, \
518+
ReadOnlyDontDelete).FromJust()
519519

520520
// Attach the uint32_t[] where each slot contains the count of the number of
521521
// callbacks waiting to be called on a particular event. It can then be

0 commit comments

Comments
 (0)