mirror of
https://github.com/mpolden/echoip.git
synced 2025-07-18 06:53:30 +02:00
Implement port testing. Fixes #11
This commit is contained in:
@ -21,6 +21,10 @@ func notFound(err error) *appError {
|
||||
return &appError{Error: err, Code: http.StatusNotFound}
|
||||
}
|
||||
|
||||
func badRequest(err error) *appError {
|
||||
return &appError{Error: err, Code: http.StatusBadRequest}
|
||||
}
|
||||
|
||||
func (e *appError) AsJSON() *appError {
|
||||
e.ContentType = APPLICATION_JSON
|
||||
return e
|
||||
|
Reference in New Issue
Block a user