refactor: remove BunString.fromJSRef (#17367)

This commit is contained in:
Don Isaac
2025-02-15 21:52:13 -08:00
committed by GitHub
parent f1a5e78033
commit 59f3d1ca31
3 changed files with 2 additions and 24 deletions

View File

@@ -1019,7 +1019,8 @@ pub const PostgresRequest = struct {
},
else => {
const str = try String.fromJSRef(value, globalObject);
const str = try String.fromJS2(value, globalObject);
if (str.tag == .Dead) return error.OutOfMemory;
defer str.deref();
const slice = str.toUTF8WithoutRef(bun.default_allocator);
defer slice.deinit();