mirror of
https://github.com/gohugoio/hugo.git
synced 2025-04-27 14:10:31 +03:00
Fix spelling and go vet errors
This commit is contained in:
parent
0d415e453b
commit
bac1ba4655
3 changed files with 4 additions and 6 deletions
|
@ -544,7 +544,7 @@ func (s *Site) ReBuild(events []fsnotify.Event) error {
|
||||||
// once readResults is finished it will close coordinator and move along
|
// once readResults is finished it will close coordinator and move along
|
||||||
<-coordinator
|
<-coordinator
|
||||||
// allow that routine to finish, then close page & fileconvchan as we've sent
|
// allow that routine to finish, then close page & fileconvchan as we've sent
|
||||||
// everthing to them we need to.
|
// everything to them we need to.
|
||||||
close(pageChan)
|
close(pageChan)
|
||||||
close(fileConvChan)
|
close(fileConvChan)
|
||||||
|
|
||||||
|
@ -553,7 +553,7 @@ func (s *Site) ReBuild(events []fsnotify.Event) error {
|
||||||
|
|
||||||
s.timerStep("read & convert pages from source")
|
s.timerStep("read & convert pages from source")
|
||||||
|
|
||||||
fmt.Errorf("%s", errs)
|
fmt.Errorf("%v", errs)
|
||||||
|
|
||||||
s.setupPrevNext()
|
s.setupPrevNext()
|
||||||
if err = s.BuildSiteMeta(); err != nil {
|
if err = s.BuildSiteMeta(); err != nil {
|
||||||
|
@ -582,8 +582,6 @@ func (s *Site) ReBuild(events []fsnotify.Event) error {
|
||||||
} else {
|
} else {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
return nil
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func (s *Site) Analyze() error {
|
func (s *Site) Analyze() error {
|
||||||
|
|
|
@ -247,7 +247,7 @@ func determineDelims(firstLine []byte) (left, right []byte) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// extractFrontMatterDelims takes a frontmatter from the content bufio.Reader.
|
// extractFrontMatterDelims takes a frontmatter from the content bufio.Reader.
|
||||||
// Begining white spaces of the bufio.Reader must be trimmed before call this
|
// Beginning white spaces of the bufio.Reader must be trimmed before call this
|
||||||
// function.
|
// function.
|
||||||
func extractFrontMatterDelims(r *bufio.Reader, left, right []byte) (fm FrontMatter, err error) {
|
func extractFrontMatterDelims(r *bufio.Reader, left, right []byte) (fm FrontMatter, err error) {
|
||||||
var (
|
var (
|
||||||
|
|
|
@ -1209,7 +1209,7 @@ func trim(a interface{}, b string) (string, error) {
|
||||||
return strings.Trim(aStr, b), nil
|
return strings.Trim(aStr, b), nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// replace all occurences of b with c in a
|
// replace all occurrences of b with c in a
|
||||||
func replace(a, b, c interface{}) (string, error) {
|
func replace(a, b, c interface{}) (string, error) {
|
||||||
aStr, err := cast.ToStringE(a)
|
aStr, err := cast.ToStringE(a)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue