Commit 6fee490
committed
fix(frontend): don't let a failed settings reload escape as a rejection
When a write fails, save() reloads the user so the screen stops showing a
value the server rejected. That reload was unguarded, so if it failed too —
the usual case, since the server that refused the write is often still down
— the rejection escaped save(). Every caller but savePreferredName invokes
it as `void save(...)`, where that surfaces as an unhandled promise
rejection rather than as anything the user can see.
The failure is now contained and the original write error left on screen: it
is the actionable one, and the value shown is the one the user typed anyway.1 parent 14964b7 commit 6fee490
1 file changed
Lines changed: 12 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
67 | 67 | | |
68 | 68 | | |
69 | 69 | | |
70 | | - | |
71 | | - | |
72 | | - | |
73 | | - | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
74 | 82 | | |
75 | 83 | | |
76 | 84 | | |
| |||
0 commit comments