@niledatabase/server 5.1.0-alpha.0 → 5.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +3 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +3 -2
- package/dist/index.mjs.map +1 -1
- package/package.json +2 -2
package/dist/index.mjs
CHANGED
|
@@ -660,6 +660,7 @@ async function auth(req, config) {
|
|
|
660
660
|
info(`using session ${sessionUrl}`);
|
|
661
661
|
req.headers.delete("content-length");
|
|
662
662
|
const res = await request(sessionUrl, { request: req }, config);
|
|
663
|
+
const cloned = res.clone();
|
|
663
664
|
try {
|
|
664
665
|
const session = await new Response(res.body).json();
|
|
665
666
|
if (Object.keys(session).length === 0) {
|
|
@@ -668,8 +669,8 @@ async function auth(req, config) {
|
|
|
668
669
|
}
|
|
669
670
|
info("session active");
|
|
670
671
|
return session;
|
|
671
|
-
} catch
|
|
672
|
-
error(
|
|
672
|
+
} catch {
|
|
673
|
+
error(cloned.text());
|
|
673
674
|
return void 0;
|
|
674
675
|
}
|
|
675
676
|
}
|