Implement helpful toString
on client APIError
This commit is contained in:
parent
d9f42caa6a
commit
38edfcc13a
|
@ -10,6 +10,9 @@ export class APIError extends Error {
|
||||||
this.name = 'APIError'
|
this.name = 'APIError'
|
||||||
this.details = details
|
this.details = details
|
||||||
}
|
}
|
||||||
|
toString() {
|
||||||
|
return this.name
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function call(url: string, method: string, params: any) {
|
export async function call(url: string, method: string, params: any) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user