mirror of
https://github.com/caddyserver/caddy.git
synced 2025-06-01 00:43:23 +08:00
chore: make the linter happier (#3245)
* chore: make the linter happier * chore: remove reference to maligned linter in .golangci.yml
This commit is contained in:

committed by
GitHub

parent
28fdf64dc5
commit
7dfd69cdc5
@ -188,7 +188,7 @@ func addHTTPVarsToReplacer(repl *caddy.Replacer, req *http.Request, w http.Respo
|
||||
if strings.HasPrefix(key, varsReplPrefix) {
|
||||
varName := key[len(varsReplPrefix):]
|
||||
tbl := req.Context().Value(VarsCtxKey).(map[string]interface{})
|
||||
raw, _ := tbl[varName]
|
||||
raw := tbl[varName]
|
||||
// variables can be dynamic, so always return true
|
||||
// even when it may not be set; treat as empty then
|
||||
return raw, true
|
||||
|
Reference in New Issue
Block a user