@niledatabase/server 5.0.3 → 5.1.0-alpha.1
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.js
CHANGED
|
@@ -666,6 +666,7 @@ async function auth(req, config) {
|
|
|
666
666
|
info(`using session ${sessionUrl}`);
|
|
667
667
|
req.headers.delete("content-length");
|
|
668
668
|
const res = await request(sessionUrl, { request: req }, config);
|
|
669
|
+
const cloned = res.clone();
|
|
669
670
|
try {
|
|
670
671
|
const session = await new Response(res.body).json();
|
|
671
672
|
if (Object.keys(session).length === 0) {
|
|
@@ -674,8 +675,8 @@ async function auth(req, config) {
|
|
|
674
675
|
}
|
|
675
676
|
info("session active");
|
|
676
677
|
return session;
|
|
677
|
-
} catch
|
|
678
|
-
error(
|
|
678
|
+
} catch {
|
|
679
|
+
error(cloned.text());
|
|
679
680
|
return void 0;
|
|
680
681
|
}
|
|
681
682
|
}
|