fix(context): verify URL is Non-nil in initQueryCache() (#3969)
This commit is contained in:
committed by
GitHub
parent
4f339e6a35
commit
e0d46ded6c
@ -475,7 +475,7 @@ func (c *Context) QueryArray(key string) (values []string) {
|
||||
|
||||
func (c *Context) initQueryCache() {
|
||||
if c.queryCache == nil {
|
||||
if c.Request != nil {
|
||||
if c.Request != nil && c.Request.URL != nil {
|
||||
c.queryCache = c.Request.URL.Query()
|
||||
} else {
|
||||
c.queryCache = url.Values{}
|
||||
|
Reference in New Issue
Block a user