Skip to content

Commit aa16235

Browse files
committed
settled, add body message, no stringy
1 parent f8e73f7 commit aa16235

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/utils/oidc.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -106,10 +106,10 @@ async function oidc ({ packageName, registry, opts, config }) {
106106
const response = await npmFetch.json(new URL('/-/npm/v1/oidc/token/exchange', registry), {
107107
...opts,
108108
method: 'POST',
109-
body: JSON.stringify({
109+
body: {
110110
package_name: packageName,
111111
id_token: idToken,
112-
}),
112+
},
113113
})
114114

115115
if (!response?.token) {
@@ -130,7 +130,7 @@ async function oidc ({ packageName, registry, opts, config }) {
130130
} catch (error) {
131131
log.verbose('oidc', error.message)
132132
if (error?.body?.message) {
133-
log.verbose('oidc', error.body.message)
133+
log.verbose('oidc', `Registry body response error message "${error.body.message}"`)
134134
}
135135
}
136136
return undefined

0 commit comments

Comments
 (0)