@absolutejs/auth 0.44.1 → 0.44.3

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 CHANGED
@@ -8222,7 +8222,11 @@ var callback = ({
8222
8222
  },
8223
8223
  query: { code, state: callback_state }
8224
8224
  }) => withSpan("auth.oauth.callback", { "auth.provider": auth_provider?.value }, async () => {
8225
- if (stored_state === undefined || code_verifier === undefined || user_session_id === undefined || auth_client === undefined || auth_intent === undefined) {
8225
+ if (stored_state === undefined || code_verifier === undefined || auth_provider === undefined || user_session_id === undefined || auth_client === undefined || auth_intent === undefined) {
8226
+ return status("Bad Request", "Cookies are missing");
8227
+ }
8228
+ const authProvider = auth_provider.value;
8229
+ if (authProvider === undefined) {
8226
8230
  return status("Bad Request", "Cookies are missing");
8227
8231
  }
8228
8232
  if (!isNonEmptyString(code) || stored_state.value === undefined) {
@@ -8241,7 +8245,6 @@ var callback = ({
8241
8245
  }
8242
8246
  const { clientName, providerInstance } = resolvedProvider.entry;
8243
8247
  stored_state.remove();
8244
- const authProvider = auth_provider.value;
8245
8248
  const requiresPKCE = isPKCEProviderOption(authProvider);
8246
8249
  const verifier = requiresPKCE ? code_verifier.value : undefined;
8247
8250
  if (requiresPKCE && verifier === undefined) {
@@ -8336,11 +8339,11 @@ var callback = ({
8336
8339
  cookie: t18.Cookie({
8337
8340
  auth_client: authClientOption,
8338
8341
  auth_intent: authIntentOption,
8339
- auth_provider: authProviderOption,
8342
+ auth_provider: t18.Optional(authProviderOption),
8340
8343
  code_verifier: t18.Optional(t18.String()),
8341
8344
  origin_url: t18.Optional(t18.String()),
8342
8345
  state: t18.Optional(t18.String()),
8343
- user_session_id: userSessionIdTypebox
8346
+ user_session_id: t18.Optional(userSessionIdTypebox)
8344
8347
  })
8345
8348
  });
8346
8349
 
@@ -26187,5 +26190,5 @@ export {
26187
26190
  AuthIdentityConflictError
26188
26191
  };
26189
26192
 
26190
- //# debugId=02ED8EE4D0AFE4F564756E2164756E21
26193
+ //# debugId=6AB6B892188E4F0164756E2164756E21
26191
26194
  //# sourceMappingURL=index.js.map