New creates new user error with the given message. By default these errors are not logged to Sentry. If you want to log the error, use NewLogged
(msg string, args ...any)
| 27 | // New creates new user error with the given message. By default these errors |
| 28 | // are not logged to Sentry. If you want to log the error, use NewLogged |
| 29 | func New(msg string, args ...any) error { |
| 30 | return errors.WithStack(&combined{ |
| 31 | userMessage: fmt.Sprintf(msg, args...), |
| 32 | }) |
| 33 | } |
| 34 | |
| 35 | // NewLogged creates new user error with the given message. These messages are |
| 36 | // logged to Sentry without the message (for privacy reasons). This is useful |
no outgoing calls
no test coverage detected