Call twirp.ServerHooks.Error if the hook is available
(ctx context.Context, h *twirp.ServerHooks, err twirp.Error)
| 1062 | |
| 1063 | // Call twirp.ServerHooks.Error if the hook is available |
| 1064 | func callError(ctx context.Context, h *twirp.ServerHooks, err twirp.Error) context.Context { |
| 1065 | if h == nil || h.Error == nil { |
| 1066 | return ctx |
| 1067 | } |
| 1068 | return h.Error(ctx, err) |
| 1069 | } |
| 1070 | |
| 1071 | func callClientResponseReceived(ctx context.Context, h *twirp.ClientHooks) { |
| 1072 | if h == nil || h.ResponseReceived == nil { |
no test coverage detected