summaryrefslogtreecommitdiffstats
path: root/hugolib/page_output.go
diff options
context:
space:
mode:
authorBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2017-03-16 08:32:14 +0100
committerBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2017-03-27 15:43:56 +0200
commit4c2abe0015393de6e7a2af119c2df5b05879fe19 (patch)
treeac7d788472ff18e4e57a160e3eefb28e095bf60f /hugolib/page_output.go
parent6bf010fed432e5574e19fd2946ee6397d895950e (diff)
Rename OutputType to OutputFormat
Diffstat (limited to 'hugolib/page_output.go')
-rw-r--r--hugolib/page_output.go12
1 files changed, 6 insertions, 6 deletions
diff --git a/hugolib/page_output.go b/hugolib/page_output.go
index 88386a6d0..90dbc9638 100644
--- a/hugolib/page_output.go
+++ b/hugolib/page_output.go
@@ -31,11 +31,11 @@ type PageOutput struct {
// Keep this to create URL/path variations, i.e. paginators.
targetPathDescriptor targetPathDescriptor
- outputType output.Type
+ outputFormat output.Format
}
func (p *PageOutput) targetPath(addends ...string) (string, error) {
- tp, err := p.createTargetPath(p.outputType, addends...)
+ tp, err := p.createTargetPath(p.outputFormat, addends...)
if err != nil {
return "", err
}
@@ -43,13 +43,13 @@ func (p *PageOutput) targetPath(addends ...string) (string, error) {
}
-func newPageOutput(p *Page, createCopy bool, outputType output.Type) (*PageOutput, error) {
+func newPageOutput(p *Page, createCopy bool, f output.Format) (*PageOutput, error) {
if createCopy {
p.initURLs()
p = p.copy()
}
- td, err := p.createTargetPathDescriptor(outputType)
+ td, err := p.createTargetPathDescriptor(f)
if err != nil {
return nil, err
@@ -57,7 +57,7 @@ func newPageOutput(p *Page, createCopy bool, outputType output.Type) (*PageOutpu
return &PageOutput{
Page: p,
- outputType: outputType,
+ outputFormat: f,
targetPathDescriptor: td,
}, nil
}
@@ -65,7 +65,7 @@ func newPageOutput(p *Page, createCopy bool, outputType output.Type) (*PageOutpu
// copy creates a copy of this PageOutput with the lazy sync.Once vars reset
// so they will be evaluated again, for word count calculations etc.
func (p *PageOutput) copy() *PageOutput {
- c, err := newPageOutput(p.Page, true, p.outputType)
+ c, err := newPageOutput(p.Page, true, p.outputFormat)
if err != nil {
panic(err)
}