mirror of
https://github.com/oven-sh/bun
synced 2026-02-12 20:09:04 +00:00
fix errors
Former-commit-id: ac66d6af52f6a2340c57a957bed078f94a8cf8ed
This commit is contained in:
@@ -55,7 +55,6 @@ pub const Response = struct {
|
||||
|
||||
pub fn finalize(
|
||||
this: *Response,
|
||||
ctx: js.JSObjectRef,
|
||||
) void {
|
||||
this.body.deinit(this.allocator);
|
||||
this.allocator.destroy(this);
|
||||
@@ -121,16 +120,15 @@ pub const Response = struct {
|
||||
// return null;
|
||||
// }
|
||||
|
||||
var tup = Repsonse.Class.makeObject(
|
||||
ctx,
|
||||
getAllocator(ctx),
|
||||
);
|
||||
|
||||
tup.ptr.* = Response{
|
||||
var response = getAllocator(ctx).create(Response) catch unreachable;
|
||||
response.* = Response{
|
||||
.body = body,
|
||||
.allocator = getAllocator(ctx),
|
||||
};
|
||||
return tup.ref;
|
||||
return Response.Class.make(
|
||||
ctx,
|
||||
response,
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
@@ -298,7 +296,6 @@ pub const Headers = struct {
|
||||
|
||||
pub fn finalize(
|
||||
this: *Headers,
|
||||
ctx: js.JSObjectRef,
|
||||
) void {
|
||||
this.deinit();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user