(request: JRPCNotification<T> | JRPCRequest<T>)
| 51 | * Type guard to check if a JRPC message is a notification (no `id` property). |
| 52 | */ |
| 53 | export function isJRPCNotification<T extends JRPCParams>(request: JRPCNotification<T> | JRPCRequest<T>): request is JRPCNotification<T> { |
| 54 | return !hasProperty(request, "id") || request.id === undefined; |
| 55 | } |
| 56 | |
| 57 | /** |
| 58 | * Type guard to check if a JRPC message is a request (has `id` property). |
no test coverage detected