Commit d3e8bcc
molty3000
fix(onError): use Function type, await async hooks, add 4 tests
- Type: use Function for onError (consistent with all other hooks in Hooks interface)
- Async: await onError call so async hooks that reject are caught by try/catch
- Tests: 4 new tests covering sync, async, throwing, and no-error paths
- All 4 new tests pass (54 total, 1 pre-existing failure unchanged)1 parent 3201de3 commit d3e8bcc
5 files changed
Lines changed: 11921 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
59 | 59 | | |
60 | 60 | | |
61 | 61 | | |
62 | | - | |
| 62 | + | |
63 | 63 | | |
64 | 64 | | |
65 | 65 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
176 | 176 | | |
177 | 177 | | |
178 | 178 | | |
179 | | - | |
| 179 | + | |
180 | 180 | | |
181 | 181 | | |
182 | 182 | | |
| |||
0 commit comments