Skip to content

Commit

Permalink
src: replace usage of deprecated Delete
Browse files Browse the repository at this point in the history
PR-URL: #5159
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
  • Loading branch information
targos authored and Ali Sheikh committed Mar 4, 2016
1 parent 16b0a8c commit d45045f
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
12 changes: 8 additions & 4 deletions src/node.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1051,7 +1051,8 @@ void SetupDomainUse(const FunctionCallbackInfo<Value>& args) {

// Do a little housekeeping.
env->process_object()->Delete(
FIXED_ONE_BYTE_STRING(args.GetIsolate(), "_setupDomainUse"));
env->context(),
FIXED_ONE_BYTE_STRING(args.GetIsolate(), "_setupDomainUse")).FromJust();

uint32_t* const fields = env->domain_flag()->fields();
uint32_t const fields_count = env->domain_flag()->fields_count();
Expand All @@ -1074,7 +1075,8 @@ void SetupProcessObject(const FunctionCallbackInfo<Value>& args) {

env->set_push_values_to_array_function(args[0].As<Function>());
env->process_object()->Delete(
FIXED_ONE_BYTE_STRING(env->isolate(), "_setupProcessObject"));
env->context(),
FIXED_ONE_BYTE_STRING(env->isolate(), "_setupProcessObject")).FromJust();
}


Expand All @@ -1090,7 +1092,8 @@ void SetupNextTick(const FunctionCallbackInfo<Value>& args) {

// Do a little housekeeping.
env->process_object()->Delete(
FIXED_ONE_BYTE_STRING(args.GetIsolate(), "_setupNextTick"));
env->context(),
FIXED_ONE_BYTE_STRING(args.GetIsolate(), "_setupNextTick")).FromJust();

// Values use to cross communicate with processNextTick.
uint32_t* const fields = env->tick_info()->fields();
Expand Down Expand Up @@ -1130,7 +1133,8 @@ void SetupPromises(const FunctionCallbackInfo<Value>& args) {
env->set_promise_reject_function(args[0].As<Function>());

env->process_object()->Delete(
FIXED_ONE_BYTE_STRING(args.GetIsolate(), "_setupPromises"));
env->context(),
FIXED_ONE_BYTE_STRING(args.GetIsolate(), "_setupPromises")).FromJust();
}


Expand Down
2 changes: 1 addition & 1 deletion src/stream_base.cc
Original file line number Diff line number Diff line change
Expand Up @@ -371,7 +371,7 @@ void StreamBase::AfterWrite(WriteWrap* req_wrap, int status) {

// Unref handle property
Local<Object> req_wrap_obj = req_wrap->object();
req_wrap_obj->Delete(env->handle_string());
req_wrap_obj->Delete(env->context(), env->handle_string()).FromJust();
wrap->OnAfterWrite(req_wrap);

Local<Value> argv[] = {
Expand Down

0 comments on commit d45045f

Please sign in to comment.