diff options
Diffstat (limited to 'pkg/config')
| -rw-r--r-- | pkg/config/config.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/pkg/config/config.go b/pkg/config/config.go index 9ff25ecd7..8eb43fa58 100644 --- a/pkg/config/config.go +++ b/pkg/config/config.go @@ -26,7 +26,7 @@ func LoadFile(filename string, cfg interface{}) error { func LoadData(data []byte, cfg interface{}) error { // Remove comment lines starting with #. - data = regexp.MustCompile(`(^|\n)\s*#.*?\n`).ReplaceAll(data, nil) + data = regexp.MustCompile(`(^|\n)\s*#[^\n]*`).ReplaceAll(data, nil) dec := json.NewDecoder(bytes.NewReader(data)) dec.DisallowUnknownFields() if err := dec.Decode(cfg); err != nil { |
