diff options
author | Cameron Moore <[email protected]> | 2017-09-25 21:25:33 -0500 |
---|---|---|
committer | Bjørn Erik Pedersen <[email protected]> | 2017-09-29 16:23:16 +0200 |
commit | 47fdfd5196cd24a23b30afe1d88969ffb413ab59 (patch) | |
tree | e2b4dc5bb5341ab2d8588879fb733ee888b9164b /source | |
parent | d45e358a0543d987091ef54b56eadd9cebda2e0f (diff) | |
download | hugo-47fdfd5196cd24a23b30afe1d88969ffb413ab59.tar.gz hugo-47fdfd5196cd24a23b30afe1d88969ffb413ab59.zip |
Clean up lint in various packages
Changes fall into one of the following:
- gofmt -s
- receiver name is inconsistent
- omit unused 2nd value from range
- godoc comment formed incorrectly
- err assigned and not used
- if block ends with a return statement followed by else
Diffstat (limited to 'source')
-rw-r--r-- | source/filesystem.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/filesystem.go b/source/filesystem.go index 446d8c06d..e6e354e99 100644 --- a/source/filesystem.go +++ b/source/filesystem.go @@ -158,14 +158,14 @@ func (f *Filesystem) avoid(filePath string) bool { return false } -func (s SourceSpec) isNonProcessablePath(filePath string) bool { +func (sp SourceSpec) isNonProcessablePath(filePath string) bool { base := filepath.Base(filePath) if strings.HasPrefix(base, ".") || strings.HasPrefix(base, "#") || strings.HasSuffix(base, "~") { return true } - ignoreFiles := cast.ToStringSlice(s.Cfg.Get("ignoreFiles")) + ignoreFiles := cast.ToStringSlice(sp.Cfg.Get("ignoreFiles")) if len(ignoreFiles) > 0 { for _, ignorePattern := range ignoreFiles { match, err := regexp.MatchString(ignorePattern, filePath) |