mirror of
https://github.com/gohugoio/hugo.git
synced 2025-09-01 22:42:45 +02:00
Misc permalinks adjustments
* Move config loading to the page package * Fix a lower bound panic for the `:sections` slice syntax. * Always return the `:title` * Add some permalinks integration tests * Also see issues below Fixes #9448 Fixes #11184 See #8523
This commit is contained in:
@@ -18,7 +18,6 @@ package page
|
||||
import (
|
||||
"github.com/gohugoio/hugo/common/loggers"
|
||||
"github.com/gohugoio/hugo/hugofs"
|
||||
"github.com/gohugoio/hugo/hugofs/files"
|
||||
"github.com/gohugoio/hugo/source"
|
||||
)
|
||||
|
||||
@@ -35,11 +34,6 @@ func (zeroFile) IsZero() bool {
|
||||
return true
|
||||
}
|
||||
|
||||
func (z zeroFile) Classifier() files.ContentClass {
|
||||
z.log.Warnln(".File.Classifier on zero object. Wrap it in if or with: {{ with .File }}{{ .Classifier }}{{ end }}")
|
||||
return files.ContentClassZero
|
||||
}
|
||||
|
||||
func (z zeroFile) Path() (o0 string) {
|
||||
z.log.Warnln(".File.Path on zero object. Wrap it in if or with: {{ with .File }}{{ .Path }}{{ end }}")
|
||||
return
|
||||
|
Reference in New Issue
Block a user