(n int)
| 103 | } |
| 104 | |
| 105 | func newTooManyRedirectsError(n int) error { |
| 106 | return TooManyRedirectsError{errctx.NewTextError( |
| 107 | fmt.Sprintf("stopped after %d redirects", n), |
| 108 | 1, |
| 109 | errctx.WithStatusCode(http.StatusNotFound), |
| 110 | errctx.WithPublicMessage(msgSourceIsUnreachable), |
| 111 | errctx.WithShouldReport(false), |
| 112 | )} |
| 113 | } |
| 114 | |
| 115 | func newRequestCanceledError(err error) error { |
| 116 | return RequestCanceledError{errctx.NewWrappedError( |
no test coverage detected