Commit 6484a56
committed
feat(client): parse nested error messages from API responses
Updates the `ErrorInterceptor` to correctly parse the standardized
nested error structure (`{"error": {"message": "..."}}`) now sent by
the `ht_api` backend.
The `_extractErrorMessage` method now prioritizes checking for this
nested format, ensuring that specific, user-friendly error messages
are extracted and propagated as the exception message. The previous
logic for flat error messages is retained as a fallback for broader
compatibility.1 parent 0b56d92 commit 6484a56
1 file changed
+11
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
89 | 89 | | |
90 | 90 | | |
91 | 91 | | |
92 | | - | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
93 | 102 | | |
94 | 103 | | |
95 | 104 | | |
96 | 105 | | |
97 | | - | |
98 | | - | |
| 106 | + | |
99 | 107 | | |
100 | 108 | | |
101 | 109 | | |
| |||
0 commit comments