Skip to content

Commit aed51a2

Browse files
pugazhendhi-mvigneshsubbiah16
authored andcommitted
Updates error reading
1 parent f222e83 commit aed51a2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/api/providers/unbound.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ export class UnboundHandler implements ApiHandler {
2828
const data = await response.json()
2929

3030
if (!response.ok) {
31-
throw new Error(data.error)
31+
throw new Error(data.error.message)
3232
}
3333

3434
yield {
@@ -42,7 +42,7 @@ export class UnboundHandler implements ApiHandler {
4242
}
4343
} catch (error) {
4444
if (error instanceof Error) {
45-
throw new Error(`Unbound Gateway completion error: ${error.message}`)
45+
throw new Error(`Unbound Gateway completion error:\n ${error.message}`)
4646
}
4747
throw error
4848
}

0 commit comments

Comments
 (0)