Skip to content

Conversation

@eswan18
Copy link
Owner

@eswan18 eswan18 commented Feb 8, 2026

Summary

  • The success redirect after OAuth login (callback/route.ts:167) was missed by Use APP_BASE_URL for all OAuth redirects #116 due to a different closing-paren pattern — still used request.url
  • The auth middleware (proxy.ts) also used request.url for login redirects
  • Both now use APP_BASE_URL with fallback to request.nextUrl.origin
  • No remaining request.url usages in the codebase

Test plan

  • Deploy to staging, complete full OAuth flow, verify redirect lands on forecasting-staging.tailc06f30.ts.net
  • Visit a protected page while logged out, verify redirect goes to /login on the correct host

🤖 Generated with Claude Code

The previous fix missed the success redirect in the callback route
(different closing paren pattern) and the middleware login redirect.
Both now use APP_BASE_URL with fallback to request origin.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@eswan18 eswan18 merged commit 6fe754d into main Feb 8, 2026
@eswan18 eswan18 deleted the fix/remaining-request-url-redirects branch February 8, 2026 20:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant