()
| 44 | } |
| 45 | |
| 46 | toJSON(): ITriplitError { |
| 47 | return { |
| 48 | name: this.name, |
| 49 | message: this.message, |
| 50 | baseMessage: this.baseMessage, |
| 51 | status: this.status, |
| 52 | contextMessage: this.contextMessage, |
| 53 | }; |
| 54 | } |
| 55 | static fromJson(json: any) { |
| 56 | const error = new TriplitError(json.contextMessage); |
| 57 | if (json.baseMessage) error.baseMessage = json.baseMessage; |
no outgoing calls
no test coverage detected