Skip to content

Commit

Permalink
Merge pull request #42046 from thaJeztah/20.10_labels_regex_length_check
Browse files Browse the repository at this point in the history
[20.10 backport] Check the length of the correct variable #42039
  • Loading branch information
tiborvass authored Feb 23, 2021
2 parents 148e6c9 + 0e00115 commit dc1606a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion daemon/logger/loginfo.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ func (info *Info) ExtraAttributes(keyMod func(string) string) (map[string]string
}

labelsRegex, ok := info.Config["labels-regex"]
if ok && len(labels) > 0 {
if ok && len(labelsRegex) > 0 {
re, err := regexp.Compile(labelsRegex)
if err != nil {
return nil, err
Expand Down

0 comments on commit dc1606a

Please sign in to comment.