refactor: add successOr, sweep remaining inline unwraps (RD-17)
Eight sites hand-rolled `rd.tag === 'Success' ? rd.value : fallback`. Six take the new `successOr(rd, fallback)`, one takes the existing `successOf`, and one (`big-profile.store.ts`) uses the existing `map`, since it returns a RemoteData rather than an unwrapped value. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
@@ -20,7 +20,7 @@ tested where._
|
||||
|
||||
Every bullet below is a real test name from the suite — an `it()` title (frontend) or a test
|
||||
method name (backend), read as a sentence. Nothing here is hand-written prose: this page
|
||||
**is** the suite, reshaped for a business reader. 530 frontend behaviours across
|
||||
**is** the suite, reshaped for a business reader. 532 frontend behaviours across
|
||||
9 contexts; 261 backend behaviours across 42 test
|
||||
classes.
|
||||
|
||||
@@ -968,6 +968,11 @@ classes.
|
||||
- unwraps a Success value
|
||||
- is undefined for every other state
|
||||
|
||||
#### successOr
|
||||
|
||||
- unwraps a Success value
|
||||
- is the fallback for every other state
|
||||
|
||||
#### upload lifecycle messages
|
||||
|
||||
- queued → progress → complete
|
||||
|
||||
Reference in New Issue
Block a user