Skip to content

Commit

Permalink
fix: fix eslint error
Browse files Browse the repository at this point in the history
  • Loading branch information
alstn2468 committed Jan 16, 2024
1 parent 8e20cf6 commit b45633c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions source/core/Ky.ts
Original file line number Diff line number Diff line change
Expand Up @@ -103,9 +103,9 @@ export class Ky {

// If error causes when call JSON.parse
try {
return response[type]();
return (await response.json());
} catch {
return await response.text()
return response.text();
}
}

Expand Down

0 comments on commit b45633c

Please sign in to comment.