mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-25 22:00:58 +02:00
Revert "Consider root and current section's content type if set in front matter"
This reverts commit c790029e1d
.
This commit is contained in:
@@ -35,12 +35,6 @@ type LayoutDescriptor struct {
|
||||
Kind string
|
||||
Lang string
|
||||
Layout string
|
||||
|
||||
// Any potential type set in the page's current section and the root section
|
||||
// it lives in.
|
||||
TypeFirstSection string
|
||||
TypeCurrentSection string
|
||||
|
||||
// LayoutOverride indicates what we should only look for the above layout.
|
||||
LayoutOverride bool
|
||||
}
|
||||
@@ -133,14 +127,6 @@ func resolvePageTemplate(d LayoutDescriptor, f Format) []string {
|
||||
b.addTypeVariations(d.Type)
|
||||
}
|
||||
|
||||
if d.TypeCurrentSection != "" {
|
||||
b.addTypeVariations(d.TypeCurrentSection)
|
||||
}
|
||||
|
||||
if d.TypeFirstSection != "" {
|
||||
b.addTypeVariations(d.TypeFirstSection)
|
||||
}
|
||||
|
||||
switch d.Kind {
|
||||
case "page":
|
||||
b.addLayoutVariations("single")
|
||||
|
Reference in New Issue
Block a user