Skip to content

Commit cb24fc7

Browse files
dario-piotrowicztargos
authored andcommitted
src: remove unused checkMessagePort internal binding
PR-URL: #58267 Reviewed-By: Yagiz Nizipli <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Darshan Sen <[email protected]> Reviewed-By: James M Snell <[email protected]> Reviewed-By: Ulises Gascón <[email protected]> Reviewed-By: Chengzhong Wu <[email protected]>
1 parent 4db5d0b commit cb24fc7

File tree

3 files changed

+0
-11
lines changed

3 files changed

+0
-11
lines changed

src/node_messaging.cc

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1141,13 +1141,6 @@ void MessagePort::Stop(const FunctionCallbackInfo<Value>& args) {
11411141
port->Stop();
11421142
}
11431143

1144-
void MessagePort::CheckType(const FunctionCallbackInfo<Value>& args) {
1145-
Environment* env = Environment::GetCurrent(args);
1146-
args.GetReturnValue().Set(
1147-
GetMessagePortConstructorTemplate(env->isolate_data())
1148-
->HasInstance(args[0]));
1149-
}
1150-
11511144
void MessagePort::Drain(const FunctionCallbackInfo<Value>& args) {
11521145
MessagePort* port;
11531146
ASSIGN_OR_RETURN_UNWRAP(&port, args[0].As<Object>());
@@ -1731,7 +1724,6 @@ static void CreatePerIsolateProperties(IsolateData* isolate_data,
17311724
// These are not methods on the MessagePort prototype, because
17321725
// the browser equivalents do not provide them.
17331726
SetMethod(isolate, target, "stopMessagePort", MessagePort::Stop);
1734-
SetMethod(isolate, target, "checkMessagePort", MessagePort::CheckType);
17351727
SetMethod(isolate, target, "drainMessagePort", MessagePort::Drain);
17361728
SetMethod(
17371729
isolate, target, "receiveMessageOnPort", MessagePort::ReceiveMessage);
@@ -1767,7 +1759,6 @@ static void RegisterExternalReferences(ExternalReferenceRegistry* registry) {
17671759
registry->Register(MessagePort::PostMessage);
17681760
registry->Register(MessagePort::Start);
17691761
registry->Register(MessagePort::Stop);
1770-
registry->Register(MessagePort::CheckType);
17711762
registry->Register(MessagePort::Drain);
17721763
registry->Register(MessagePort::ReceiveMessage);
17731764
registry->Register(MessagePort::MoveToContext);

src/node_messaging.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,6 @@ class MessagePort : public HandleWrap {
261261
static void PostMessage(const v8::FunctionCallbackInfo<v8::Value>& args);
262262
static void Start(const v8::FunctionCallbackInfo<v8::Value>& args);
263263
static void Stop(const v8::FunctionCallbackInfo<v8::Value>& args);
264-
static void CheckType(const v8::FunctionCallbackInfo<v8::Value>& args);
265264
static void Drain(const v8::FunctionCallbackInfo<v8::Value>& args);
266265
static void ReceiveMessage(const v8::FunctionCallbackInfo<v8::Value>& args);
267266

typings/internalBinding/messaging.d.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ export interface MessagingBinding {
2323
MessagePort: typeof InternalMessagingBinding.MessagePort;
2424
JSTransferable: typeof InternalMessagingBinding.JSTransferable;
2525
stopMessagePort(port: typeof InternalMessagingBinding.MessagePort): void;
26-
checkMessagePort(port: unknown): boolean;
2726
drainMessagePort(port: typeof InternalMessagingBinding.MessagePort): void;
2827
receiveMessageOnPort(port: typeof InternalMessagingBinding.MessagePort): any;
2928
moveMessagePortToContext(port: typeof InternalMessagingBinding.MessagePort, context: any): typeof InternalMessagingBinding.MessagePort;

0 commit comments

Comments
 (0)