@absolutejs/auth 0.22.6 → 0.22.7
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 +18 -15
- package/dist/index.js.map +3 -3
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -3192,19 +3192,22 @@ var signout = ({
|
|
|
3192
3192
|
userSessionId: user_session_id.value
|
|
3193
3193
|
});
|
|
3194
3194
|
const signoutSession = authSessionStore ? compatibilityLayer.session : session;
|
|
3195
|
-
|
|
3196
|
-
|
|
3197
|
-
|
|
3198
|
-
|
|
3199
|
-
|
|
3200
|
-
|
|
3201
|
-
|
|
3202
|
-
|
|
3203
|
-
|
|
3204
|
-
error
|
|
3205
|
-
|
|
3206
|
-
|
|
3207
|
-
|
|
3195
|
+
const currentSession = signoutSession[user_session_id.value];
|
|
3196
|
+
if (currentSession !== undefined) {
|
|
3197
|
+
try {
|
|
3198
|
+
await onSignOut?.({
|
|
3199
|
+
authProvider: auth_provider.value,
|
|
3200
|
+
session: signoutSession,
|
|
3201
|
+
userSessionId: user_session_id.value
|
|
3202
|
+
});
|
|
3203
|
+
} catch (err) {
|
|
3204
|
+
console.error("[signout] Sign out operation failed:", {
|
|
3205
|
+
authProvider: auth_provider.value,
|
|
3206
|
+
error: err instanceof Error ? err.message : err,
|
|
3207
|
+
stack: err instanceof Error ? err.stack : undefined
|
|
3208
|
+
});
|
|
3209
|
+
return status("Internal Server Error", "Sign out operation failed");
|
|
3210
|
+
}
|
|
3208
3211
|
}
|
|
3209
3212
|
delete signoutSession[user_session_id.value];
|
|
3210
3213
|
if (authSessionStore) {
|
|
@@ -3219,7 +3222,7 @@ var signout = ({
|
|
|
3219
3222
|
return new Response(null, { status: 204 });
|
|
3220
3223
|
}, {
|
|
3221
3224
|
cookie: t8.Cookie({
|
|
3222
|
-
auth_provider: authProviderOption,
|
|
3225
|
+
auth_provider: t8.Optional(authProviderOption),
|
|
3223
3226
|
user_session_id: t8.Optional(t8.TemplateLiteral("${string}-${string}-${string}-${string}-${string}"))
|
|
3224
3227
|
})
|
|
3225
3228
|
});
|
|
@@ -13879,5 +13882,5 @@ export {
|
|
|
13879
13882
|
AbsoluteAuthIdentityConflictError
|
|
13880
13883
|
};
|
|
13881
13884
|
|
|
13882
|
-
//# debugId=
|
|
13885
|
+
//# debugId=7F98E858A24BE38A64756E2164756E21
|
|
13883
13886
|
//# sourceMappingURL=index.js.map
|