refactor
This commit is contained in:
@@ -1,14 +1,17 @@
|
||||
/**
|
||||
* @deprecated Use error codes in Result instead of throwing ApplicationError.
|
||||
* @deprecated Use ApplicationErrorCode in Result instead of throwing ApplicationError.
|
||||
*/
|
||||
export type CommonApplicationErrorKind =
|
||||
| 'not_found'
|
||||
| 'forbidden'
|
||||
| 'conflict'
|
||||
| 'validation'
|
||||
| 'unknown'
|
||||
| string;
|
||||
| 'not_found'
|
||||
| 'forbidden'
|
||||
| 'conflict'
|
||||
| 'validation'
|
||||
| 'unknown'
|
||||
| string;
|
||||
|
||||
/**
|
||||
* @deprecated Use ApplicationErrorCode in Result instead of throwing ApplicationError.
|
||||
*/
|
||||
export interface IApplicationError<K extends string = CommonApplicationErrorKind, D = unknown> extends Error {
|
||||
readonly type: 'application';
|
||||
readonly context: string;
|
||||
|
||||
Reference in New Issue
Block a user