(after time.Duration)
| 63 | } |
| 64 | |
| 65 | func newRequestCancelledError(after time.Duration) errctx.Error { |
| 66 | return RequestCancelledError{errctx.NewTextError( |
| 67 | fmt.Sprintf("Request was cancelled after %v", after), |
| 68 | 1, |
| 69 | errctx.WithStatusCode(499), |
| 70 | errctx.WithPublicMessage("Cancelled"), |
| 71 | errctx.WithShouldReport(false), |
| 72 | )} |
| 73 | } |
| 74 | |
| 75 | func (e RequestCancelledError) Unwrap() error { |
| 76 | return context.Canceled |
no test coverage detected