Commit 009fa3f
committed
fix: OAuth redirect loop — revert to server-side redirect, force secure cookie
Two issues:
1. Client-side HTML meta-refresh redirect (added for double-login fix) had
broken JS syntax in template literal and was unreliable across browsers.
Reverted to simple NextResponse.redirect().
2. Cookie secure flag was conditional on NODE_ENV=production which may not
be set on Amplify Lambda. Changed to always true (site is HTTPS-only).1 parent 5da50e6 commit 009fa3f
1 file changed
Lines changed: 2 additions & 11 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
103 | 103 | | |
104 | 104 | | |
105 | 105 | | |
106 | | - | |
107 | | - | |
108 | | - | |
109 | | - | |
110 | | - | |
111 | | - | |
112 | | - | |
113 | | - | |
114 | | - | |
115 | | - | |
| 106 | + | |
116 | 107 | | |
117 | 108 | | |
118 | 109 | | |
119 | | - | |
| 110 | + | |
120 | 111 | | |
121 | 112 | | |
122 | 113 | | |
| |||
0 commit comments