fix(net): use exec.js.local in collectBodyBytes

Drop nested localScope; fetch already runs under an active Caller local.
Fixes compile error where &ls (Scope) was passed where *js.Local is required.
This commit is contained in:
arimu1
2026-07-25 09:23:18 +07:00
parent fdc98b7e4b
commit f47dac832f

View File

@@ -142,12 +142,7 @@ pub fn collectBodyBytes(self: *ReadableStream, arena: std.mem.Allocator) ![]cons
}
const exec = self._execution;
if (exec.js.local == null) return error.TypeError;
var ls: js.Local.Scope = undefined;
exec.js.localScope(&ls);
defer ls.deinit();
const local = &ls;
const local = exec.js.local orelse return error.TypeError;
var buf = std.Io.Writer.Allocating.init(arena);
const controller = self._controller;