(e *Error)
| 90 | } |
| 91 | |
| 92 | func walkErrorStack(e *Error) string { |
| 93 | if e == nil { |
| 94 | return "" |
| 95 | } |
| 96 | |
| 97 | switch e.Err.(type) { |
| 98 | case *Error: |
| 99 | return fmt.Sprintf("\n <- HTTP %d (%s) at %s from", e.Status, http.StatusText(e.Status), e.Origin) + walkErrorStack(e.Err.(*Error)) |
| 100 | default: |
| 101 | return fmt.Sprintf("\n <- HTTP %d (%s) at %s: %+v", e.Status, http.StatusText(e.Status), e.Origin, e.Err) |
| 102 | } |
| 103 | } |
| 104 | |
| 105 | // 1xx |
| 106 | func NewErrorContinue(err error) *Error { return NewError(http.StatusContinue, err) } |