( code: string, surfaceId: string, message: string, details?: Record<string, unknown>, )
| 721 | * 创建通用错误 |
| 722 | */ |
| 723 | export function createGenericError( |
| 724 | code: string, |
| 725 | surfaceId: string, |
| 726 | message: string, |
| 727 | details?: Record<string, unknown>, |
| 728 | ): ProtocolError { |
| 729 | return { |
| 730 | code, |
| 731 | surfaceId, |
| 732 | message, |
| 733 | details, |
| 734 | }; |
| 735 | } |
| 736 | |
| 737 | // ================== |
| 738 | // 工具函数类型 |
no outgoing calls
no test coverage detected