v0.3.1
Patch Changes
-
70f126d: Keep the API token out of the errors the client throws
ApiErrorstored the options of the failed query verbatim, soerror.options.token
held the API token in clear text — and travelled with the error into
console.error()output shipped to log aggregators, into error trackers, and
into any HTTP handler that echoed the error back to its caller.The token is now replaced by
[REDACTED, ending in abcd], which still tells two
tokens apart while debugging; the real one only ever reaches theAuthorization
header. For the same reasonquery,optionsandresponseare now
non-enumerable: readingerror.optionsexplicitly works exactly as before, but
the details of the failed query no longer travel throughJSON.stringify(),
object spread orserialize-errorby accident.