Skip to content

Commit 1bb1813

Browse files
Fix instanceOf method
1 parent e3997cc commit 1bb1813

File tree

1 file changed

+2
-1
lines changed
  • packages/npm-packages/ruby-wasm-wasi/src

1 file changed

+2
-1
lines changed

packages/npm-packages/ruby-wasm-wasi/src/vm.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -291,8 +291,9 @@ export class RubyVM {
291291
return toJSAbiValue(this.transport.consumeJsValue());
292292
},
293293
instanceOf: (value, klass) => {
294+
klass = fromJSAbiValue(klass);
294295
if (typeof klass === "function") {
295-
return value instanceof klass;
296+
return fromJSAbiValue(value) instanceof klass;
296297
} else {
297298
return false;
298299
}

0 commit comments

Comments
 (0)