[Employer Sync 6.2] Handle the membership-less employer (stop redirecting to create-account)
TL;DR: Stop withOrgAuth from redirecting a logged-in user with no Org::Membership to /employers/create-account (the loop). Render a stop-page asking them to wait or contact support. Do not auto-create a company.
Context
If a migrated Identities::User ends up without an Org::Membership — because their company was not (or cannot be) migrated to JodApp — the current withOrgAuth HOC in jodapp-web redirects them to /employers/create-account, asking them to create a company that already exists.
Problem
The user cannot create the company. Registration number / slug collisions block them. They land in a loop and contact support. After the data audit, this case is small (the 90 orphan employers in sets B + C are skipped at sync time, so it should not happen — but it can happen if a company sync race or a JodApp-native edge case produces the state).
Direction
In app/components/hocs/with-org-auth.jsx:
- Detect the state — logged in
Identities::User, noOrg::Membership(orgUserProfileis nil). - Do not redirect to
/employers/create-account. - Instead, render a clear stop-page:
- Heading:
We are setting up your account - Body:
Your account exists, but it is not connected to a company yet. This usually clears in a few minutes. If you still see this in an hour, please contact support. - Single action:
Refresh(calls the user reload) + a quietNeed help? Contact support.link.
- Heading:
- Do not auto-create an
Org::Company.
The /employers/create-account route stays — it serves genuine JodApp-native signups. Just nothing should redirect to it automatically from this state.
Pair with issue 6.3's "honest login states" — the design vocabulary should match.
Acceptance
- Test: a logged-in user with no
Org::Membershiplands on the new stop-page, not/employers/create-account. - Test:
/employers/create-accountis still reachable by direct navigation (it is the signup path). - The stop-page uses stock Bootstrap / react-bootstrap classes — no custom CSS.