-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy patherrors.d.ts
More file actions
24 lines (22 loc) · 773 Bytes
/
errors.d.ts
File metadata and controls
24 lines (22 loc) · 773 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
export declare type ErrMessage = string
export declare const ALREADY_CONNECTED: ErrMessage,
NOT_CONNECTED: ErrMessage,
ERR_NETWORK: ErrMessage,
INVALID_ARGUMENTS: ErrMessage,
INVALID_ARGUMENT_WITH_CS: (val: string) => ErrMessage,
NOT_SUBSCRIBED: ErrMessage,
ALREADY_SUBSCRIBED: ErrMessage,
ADDRESSES_IS_EMPTY: ErrMessage,
BLOCK_NOT_FOUND: ErrMessage,
TRANSACTION_TYPE_NOT_VALID: ErrMessage,
TRANSACTION_NOT_BROADCAST: ErrMessage
export declare class FetchError extends Error {
code: number
response: Record<string, any>
originError?: Error
constructor(message: string)
setStatus(status: number): FetchError
setCode(code: number): FetchError
setResponse(data: Record<string, any>): FetchError
setOriginError(error: Error): FetchError
}