mirror of
https://github.com/gin-gonic/gin.git
synced 2026-06-04 09:48:17 +08:00
docs: clarify comment for bodyAllowedForStatus
This commit is contained in:
parent
7f07058407
commit
6f71a7b5d1
@ -1056,7 +1056,8 @@ func (c *Context) requestHeader(key string) string {
|
|||||||
/************************************/
|
/************************************/
|
||||||
|
|
||||||
// bodyAllowedForStatus is a copy of http.bodyAllowedForStatus non-exported function.
|
// bodyAllowedForStatus is a copy of http.bodyAllowedForStatus non-exported function.
|
||||||
// Use http.StatusContinue constant for better code clarity
|
// Uses http.StatusContinue constant for better code clarity.
|
||||||
|
// Upper bound 199 covers all 1xx informational status codes.
|
||||||
func bodyAllowedForStatus(status int) bool {
|
func bodyAllowedForStatus(status int) bool {
|
||||||
switch {
|
switch {
|
||||||
case status >= http.StatusContinue && status < http.StatusOK:
|
case status >= http.StatusContinue && status < http.StatusOK:
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user