aboutsummaryrefslogtreecommitdiff
path: root/src/bun.js/api/bun.zig
diff options
context:
space:
mode:
Diffstat (limited to 'src/bun.js/api/bun.zig')
-rw-r--r--src/bun.js/api/bun.zig10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/bun.js/api/bun.zig b/src/bun.js/api/bun.zig
index e01868af6..8a75c3653 100644
--- a/src/bun.js/api/bun.zig
+++ b/src/bun.js/api/bun.zig
@@ -282,8 +282,8 @@ pub fn getStdin(
blob.* = JSC.WebCore.Blob.initWithStore(store, ctx.ptr());
return ctx.ptr().putCachedObject(
- &ZigString.init("BunSTDIN"),
- JSC.JSValue.fromRef(JSC.WebCore.Blob.Class.make(ctx, blob)),
+ ZigString.static("BunSTDIN"),
+ blob.toJS(ctx),
).asObjectRef();
}
@@ -305,8 +305,8 @@ pub fn getStderr(
blob.* = JSC.WebCore.Blob.initWithStore(store, ctx.ptr());
return ctx.ptr().putCachedObject(
- &ZigString.init("BunSTDERR"),
- JSC.JSValue.fromRef(JSC.WebCore.Blob.Class.make(ctx, blob)),
+ ZigString.static("BunSTDERR"),
+ blob.toJS(ctx),
).asObjectRef();
}
@@ -329,7 +329,7 @@ pub fn getStdout(
return ctx.ptr().putCachedObject(
&ZigString.init("BunSTDOUT"),
- JSC.JSValue.fromRef(JSC.WebCore.Blob.Class.make(ctx, blob)),
+ blob.toJS(ctx),
).asObjectRef();
}