mirror of
https://github.com/steveiliop56/tinyauth.git
synced 2025-11-03 15:45:51 +00:00
feat: add cookie domain back to context controller
This commit is contained in:
@@ -14,7 +14,7 @@ import { Navigate, useLocation, useNavigate } from "react-router";
|
||||
import { useEffect, useState } from "react";
|
||||
|
||||
export const ContinuePage = () => {
|
||||
const { rootDomain } = useAppContext();
|
||||
const { cookieDomain } = useAppContext();
|
||||
const { isLoggedIn } = useUserContext();
|
||||
const { search } = useLocation();
|
||||
const { t } = useTranslation();
|
||||
@@ -33,8 +33,8 @@ export const ContinuePage = () => {
|
||||
: null;
|
||||
const isTrustedRedirectUri =
|
||||
redirectUriObj !== null
|
||||
? redirectUriObj.hostname === rootDomain ||
|
||||
redirectUriObj.hostname.endsWith(`.${rootDomain}`)
|
||||
? redirectUriObj.hostname === cookieDomain ||
|
||||
redirectUriObj.hostname.endsWith(`.${cookieDomain}`)
|
||||
: false;
|
||||
const isAllowedRedirectProto =
|
||||
redirectUriObj !== null
|
||||
@@ -105,7 +105,7 @@ export const ContinuePage = () => {
|
||||
components={{
|
||||
code: <code />,
|
||||
}}
|
||||
values={{ rootDomain }}
|
||||
values={{ cookieDomain }}
|
||||
/>
|
||||
</CardDescription>
|
||||
</CardHeader>
|
||||
|
||||
Reference in New Issue
Block a user