Commit 479ec12
fix(dashboard): surface JSON parse errors in TemplatePicker handleApply
The silent .catch(() => ({})) swallowed malformed server responses
and fabricated an empty data object, showing a fake 'already active'
UI state when the backend actually returned something unparseable.
Drop the inline .catch so res.json() failures propagate to the
existing outer try/catch, which surfaces a user-visible
'Failed to apply template' error via setError.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent ccca57d commit 479ec12
1 file changed
Lines changed: 1 addition & 1 deletion
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
149 | 149 | | |
150 | 150 | | |
151 | 151 | | |
152 | | - | |
| 152 | + | |
153 | 153 | | |
154 | 154 | | |
155 | 155 | | |
| |||
0 commit comments