mirror of
https://github.com/pagefaultgames/rogueserver.git
synced 2025-04-03 03:27:13 +08:00
15 lines
237 B
Go
15 lines
237 B
Go
package errors
|
|
|
|
type HttpError struct {
|
|
Code int
|
|
Message string
|
|
}
|
|
|
|
func NewHttpError(code int, message string) *HttpError {
|
|
return &HttpError{Code: code, Message: message}
|
|
}
|
|
|
|
func (h HttpError) Error() string {
|
|
return h.Message
|
|
}
|