Repository navigation
Commit ab7ba22
fix(auth): honor explicit ?inviteCode= before the offboard guard on the root page
cubic review (CS-569, P2): the centralization refactor made the root page
short-circuit offboarded users to /auth/access-removed before the /setup
passthrough, so an explicit ?inviteCode= on / was swallowed for offboarded
users — a regression from the prior behavior where 0-org users fell through
to /setup (which hands the code to /invite downstream).
Restore invite-first precedence: when ?inviteCode= is present, redirect to
/setup (preserving the code) so the downstream /invite handling runs, before
applying the offboard guard. Mirrors the /setup route precedence.
Adds a regression test: offboarded + ?inviteCode= -> /setup (not access-removed).
Refs: CS-569
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01M6zcF9bvPP1UwZgzK21cw11 parent 43d9195 commit ab7ba22
2 files changed
Lines changed: 22 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
79 | 79 | | |
80 | 80 | | |
81 | 81 | | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
82 | 94 | | |
83 | 95 | | |
84 | 96 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
59 | 59 | | |
60 | 60 | | |
61 | 61 | | |
62 | | - | |
63 | | - | |
64 | | - | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
65 | 72 | | |
66 | 73 | | |
67 | 74 | | |
| |||
0 commit comments