19 lines
1.5 KiB
Markdown
19 lines
1.5 KiB
Markdown
# 0016 Unfinished creators stay on step 5, from the session
|
|
|
|
Status: Proposed · Area: architecture · Date: 2026-10-06 · Decided by: agent
|
|
|
|
## Context
|
|
R2-CompleteProfile 4.2: a creator's channel, publishing and prices stay unavailable until step 5 is done, and the next login opens step 5 again. Before, only a fresh login knew, through its own profile read.
|
|
|
|
## Decision
|
|
- The API's session answers (login, session, refresh, registration) carry `needsProfile`, and the auth store keeps it; `completeCreatorProfile`, and step 5 or its end finding the profile complete, clear it.
|
|
- `OnboardingGuard`, rendered by the layouts of the locked routes (`compose`, `dashboard/pricing`), sends such a creator to step 5 with the current page as `?redirect=`; `GuestGuard` does the same on the auth pages. Neither changes the server render. Every other page, such as the terms, stays open.
|
|
- Step 5 sends a creator whose profile is already complete on to `?redirect=`, else their channel. The channel itself stays hidden by the back end (unapproved creators answer 404).
|
|
|
|
## Alternatives
|
|
- Read the profile in the browser after each session read: rejected; an extra serial request per page load, and a failed read let the creator in.
|
|
- Guard every page outside onboarding: rejected; it locked pages the design keeps open, such as the terms linked from step 5's support.
|
|
|
|
## Consequences
|
|
- The trader service answers one more call per creator session read; a failed call counts as not done. The back end still enforces the lock on posting and tiers (0014).
|