mirror of
https://github.com/m1k1o/neko.git
synced 2025-05-17 02:57:04 +02:00
http response name convention.
This commit is contained in:
parent
3f312c84ad
commit
c4978ba376
6 changed files with 11 additions and 11 deletions
|
@ -50,11 +50,11 @@ func HttpBadRequest(w http.ResponseWriter, res ...interface{}) {
|
|||
defHttpError(w, http.StatusBadRequest, "Bad Request.", res...)
|
||||
}
|
||||
|
||||
func HttpNotAuthorized(w http.ResponseWriter, res ...interface{}) {
|
||||
func HttpUnauthorized(w http.ResponseWriter, res ...interface{}) {
|
||||
defHttpError(w, http.StatusUnauthorized, "Access token does not have the required scope.", res...)
|
||||
}
|
||||
|
||||
func HttpNotAuthenticated(w http.ResponseWriter, res ...interface{}) {
|
||||
func HttpForbidden(w http.ResponseWriter, res ...interface{}) {
|
||||
defHttpError(w, http.StatusForbidden, "Invalid or missing access token.", res...)
|
||||
}
|
||||
|
||||
|
@ -66,7 +66,7 @@ func HttpUnprocessableEntity(w http.ResponseWriter, res ...interface{}) {
|
|||
defHttpError(w, http.StatusUnprocessableEntity, "Unprocessable Entity.", res...)
|
||||
}
|
||||
|
||||
func HttpInternalServer(w http.ResponseWriter, res ...interface{}) {
|
||||
func HttpInternalServerError(w http.ResponseWriter, res ...interface{}) {
|
||||
defHttpError(w, http.StatusInternalServerError, "Internal server error.", res...)
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue