summaryrefslogtreecommitdiffhomepage
path: root/commands
diff options
context:
space:
mode:
authorBjørn Erik Pedersen <[email protected]>2018-05-23 10:03:11 +0200
committerBjørn Erik Pedersen <[email protected]>2018-05-23 10:03:11 +0200
commit35ccf06daeaf86176c1341dde4207c3b11653d7a (patch)
tree1191bc00ec7452cea7b399ed9906254b2d57c729 /commands
parent4ddcf52ccc7af3e23109ebaac1f0486087a212ba (diff)
downloadhugo-35ccf06daeaf86176c1341dde4207c3b11653d7a.tar.gz
hugo-35ccf06daeaf86176c1341dde4207c3b11653d7a.zip
Fix some recently broken embedded templates
And add tests for them. Fixes #4757
Diffstat (limited to 'commands')
-rw-r--r--commands/hugo.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/commands/hugo.go b/commands/hugo.go
index e2d447768..b898a9b7b 100644
--- a/commands/hugo.go
+++ b/commands/hugo.go
@@ -84,11 +84,11 @@ func Execute(args []string) Response {
}
if err == nil {
- errCount := jww.LogCountForLevelsGreaterThanorEqualTo(jww.LevelError)
+ errCount := int(jww.LogCountForLevelsGreaterThanorEqualTo(jww.LevelError))
if errCount > 0 {
err = fmt.Errorf("logged %d errors", errCount)
} else if resp.Result != nil {
- errCount = resp.Result.Log.LogCountForLevelsGreaterThanorEqualTo(jww.LevelError)
+ errCount = resp.Result.NumLogErrors()
if errCount > 0 {
err = fmt.Errorf("logged %d errors", errCount)
}