Closed DanielRivers closed 1 month ago
The recent changes to LoginLink.js
improve the handling of the postLoginRedirectURL
parameter by appending the host if it starts with a '/'. Additionally, the href
attribute is now updated to use the authUrl
variable, ensuring a more accurate and secure redirection process after login.
Files | Change Summary |
---|---|
src/components/LoginLink.js |
Enhanced postLoginRedirectURL handling by appending the host if it starts with '/'. Updated href attribute to use authUrl . |
sequenceDiagram
participant User
participant LoginLink
participant AuthServer
User->>LoginLink: Click on LoginLink
LoginLink->>LoginLink: Check postLoginRedirectURL
LoginLink->>LoginLink: Append host if starts with '/'
LoginLink->>AuthServer: Redirect to authUrl
AuthServer-->>User: Redirect to postLoginRedirectURL
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
Explain your changes
When reletive URL is passed to the
postLoginRedirectURL
property of login, append the host.Resolves: https://github.com/kinde-oss/kinde-auth-nextjs/issues/174
Checklist
🛟 If you need help, consider asking for advice over in the Kinde community.