Skip to content

Commit 959379f

Browse files
committed
Make instanceof static
1 parent 671a02e commit 959379f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Sources/JavaScriptKit/JSObject.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,8 @@ public class JSObjectRef: Equatable {
3030
set { setJSValue(this: self, index: Int32(index), value: newValue) }
3131
}
3232

33-
public func instanceof(_ constructor: JSFunctionRef) -> Bool {
34-
_instanceof(self.id, constructor.id)
33+
public static func instanceof(_ instance: JSObjectRef, constructor: JSFunctionRef) -> Bool {
34+
_instanceof(instance.id, constructor.id)
3535
}
3636

3737
static let _JS_Predef_Value_Global: UInt32 = 0

0 commit comments

Comments
 (0)