mirror of
https://github.com/public-transport/db-vendo-client.git
synced 2025-02-23 07:09:35 +02:00
handle H_UNKNOWN error
see also schildbach/public-transport-enabler#0f6862f
This commit is contained in:
parent
2993cc0e87
commit
43b4a6e6d9
1 changed files with 6 additions and 0 deletions
|
@ -7,6 +7,12 @@ const SERVER_ERROR = 'SERVER_ERROR'
|
||||||
|
|
||||||
// https://gist.github.com/derhuerst/79d49c0f04c1c192a5d15756e5af575f/edit
|
// https://gist.github.com/derhuerst/79d49c0f04c1c192a5d15756e5af575f/edit
|
||||||
const byErrorCode = Object.assign(Object.create(null), {
|
const byErrorCode = Object.assign(Object.create(null), {
|
||||||
|
H_UNKNOWN: {
|
||||||
|
isServer: false,
|
||||||
|
code: SERVER_ERROR,
|
||||||
|
message: 'unknown internal error',
|
||||||
|
statusCode: 500,
|
||||||
|
},
|
||||||
AUTH: {
|
AUTH: {
|
||||||
isClient: true,
|
isClient: true,
|
||||||
code: ACCESS_DENIED,
|
code: ACCESS_DENIED,
|
||||||
|
|
Loading…
Add table
Reference in a new issue