@@ -800,7 +800,7 @@ void MessagePort::OnMessage(MessageProcessingMode mode) {
800
800
801
801
HandleScope handle_scope (env ()->isolate ());
802
802
Local<Context> context =
803
- object (env ()->isolate ())->GetCreationContext (). ToLocalChecked ();
803
+ object (env ()->isolate ())->GetCreationContextChecked ();
804
804
805
805
size_t processing_limit;
806
806
if (mode == MessageProcessingMode::kNormalOperation ) {
@@ -1057,7 +1057,7 @@ bool GetTransferList(Environment* env,
1057
1057
void MessagePort::PostMessage (const FunctionCallbackInfo<Value>& args) {
1058
1058
Environment* env = Environment::GetCurrent (args);
1059
1059
Local<Object> obj = args.This ();
1060
- Local<Context> context = obj->GetCreationContext (). ToLocalChecked ();
1060
+ Local<Context> context = obj->GetCreationContextChecked ();
1061
1061
1062
1062
if (args.Length () == 0 ) {
1063
1063
return THROW_ERR_MISSING_ARGS (env, " Not enough arguments to "
@@ -1143,9 +1143,9 @@ void MessagePort::ReceiveMessage(const FunctionCallbackInfo<Value>& args) {
1143
1143
return ;
1144
1144
}
1145
1145
1146
- MaybeLocal<Value> payload = port-> ReceiveMessage (
1147
- port->object ()-> GetCreationContext (). ToLocalChecked (),
1148
- MessageProcessingMode::kForceReadMessages );
1146
+ MaybeLocal<Value> payload =
1147
+ port->ReceiveMessage (port-> object ()-> GetCreationContextChecked (),
1148
+ MessageProcessingMode::kForceReadMessages );
1149
1149
if (!payload.IsEmpty ())
1150
1150
args.GetReturnValue ().Set (payload.ToLocalChecked ());
1151
1151
}
@@ -1610,7 +1610,7 @@ static void MessageChannel(const FunctionCallbackInfo<Value>& args) {
1610
1610
return ;
1611
1611
}
1612
1612
1613
- Local<Context> context = args.This ()->GetCreationContext (). ToLocalChecked ();
1613
+ Local<Context> context = args.This ()->GetCreationContextChecked ();
1614
1614
Context::Scope context_scope (context);
1615
1615
1616
1616
MessagePort* port1 = MessagePort::New (env, context);
0 commit comments