fix(desktop): wire serializeJsonBody into OAuth request path

The salvaged helper exported serializeJsonBody but main.cjs still inline-built
the request body, leaving the export dead and the test decoupled from the real
path. Use it at the fetchJsonViaOauthSession site so the helper's coverage
exercises production body construction. Byte-identical output.
This commit is contained in:
teknium1
2026-06-05 18:04:45 -07:00
committed by Teknium
parent b8234e7599
commit be2c64be02
+1 -1
View File
@@ -3468,7 +3468,7 @@ function fetchJsonViaOauthSession(url, options = {}) {
reject(new Error(`Unsupported Hermes backend URL protocol: ${parsed.protocol}`))
return
}
const body = options.body === undefined ? undefined : Buffer.from(JSON.stringify(options.body))
const body = serializeJsonBody(options.body)
const timeoutMs = resolveTimeoutMs(options.timeoutMs, DEFAULT_FETCH_TIMEOUT_MS)
const request = electronNet.request({