Skip to content

Commit 4f96018

Browse files
committed
fix: add res.status to error message
1 parent 18b5b2a commit 4f96018

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

create-fetchival.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ function createFetchival({ fetch }) {
3232
return res.json()
3333
}
3434

35-
const err = new Error(res.statusText)
35+
const err = new Error(`${res.status} ${res.statusText || ''}`)
3636
err.response = res
3737
throw err
3838
}

0 commit comments

Comments
 (0)