allow zig js host functions to return JSError (#15120)

This commit is contained in:
Meghan Denny
2024-11-13 21:11:56 -08:00
committed by GitHub
parent 32ddf343ee
commit fdd8d35845
70 changed files with 827 additions and 876 deletions

View File

@@ -2297,7 +2297,7 @@ pub const bindings = struct {
// return obj;
// }
pub fn jsReadTarball(global: *JSGlobalObject, callFrame: *CallFrame) JSValue {
pub fn jsReadTarball(global: *JSGlobalObject, callFrame: *CallFrame) bun.JSError!JSValue {
const args = callFrame.arguments(1).slice();
if (args.len < 1 or !args[0].isString()) {
global.throw("expected tarball path string argument", .{});