add comments to functions

This commit is contained in:
Javier Fabrizio 2023-07-11 15:56:45 -03:00
parent 14247a51e5
commit 6e891029bf
1 changed files with 2 additions and 1 deletions

View File

@ -1180,11 +1180,12 @@ func (c *Context) SetAccepted(formats ...string) {
/***** GOLANG.ORG/X/NET/CONTEXT *****/ /***** GOLANG.ORG/X/NET/CONTEXT *****/
/************************************/ /************************************/
// hasRequestContext returns whether c.Request has Context and fallback. // hasFallback returns whether c.engine has ContextWithFallback.
func (c *Context) hasFallback() bool { func (c *Context) hasFallback() bool {
return c.engine != nil && c.engine.ContextWithFallback return c.engine != nil && c.engine.ContextWithFallback
} }
// hasRequestContext returns whether c.Request has Context
func (c *Context) hasRequestContext() bool { func (c *Context) hasRequestContext() bool {
return c.Request != nil && c.Request.Context() != nil return c.Request != nil && c.Request.Context() != nil
} }