Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/gohugoio/hugo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJacob Gillespie <jacobwgillespie@gmail.com>2015-01-05 21:18:34 +0300
committerbep <bjorn.erik.pedersen@gmail.com>2015-01-05 23:00:22 +0300
commit4adf58cce7cfa22401dcb68897fd60142a83885d (patch)
tree6f7172cddb604933e6543ee7544062e407613c47 /helpers
parentb7716948bcdbf1703149c315f13fde63b067af7b (diff)
Group both options under Blackfriday: documentIDAnchor
Diffstat (limited to 'helpers')
-rw-r--r--helpers/content.go5
1 files changed, 1 insertions, 4 deletions
diff --git a/helpers/content.go b/helpers/content.go
index baccc8574..8770c88e7 100644
--- a/helpers/content.go
+++ b/helpers/content.go
@@ -85,11 +85,8 @@ func GetHtmlRenderer(defaultFlags int, ctx RenderingContext) blackfriday.Rendere
FootnoteReturnLinkContents: viper.GetString("FootnoteReturnLinkContents"),
}
- if len(ctx.DocumentId) != 0 && !viper.GetBool("DisableFootnoteAnchorPrefix") {
+ if m, ok := ctx.ConfigFlags["documentIDAnchor"]; ok && m && len(ctx.DocumentId) != 0 {
renderParameters.FootnoteAnchorPrefix = ctx.DocumentId + ":" + renderParameters.FootnoteAnchorPrefix
- }
-
- if len(ctx.DocumentId) != 0 && !viper.GetBool("DisableHeaderIDSuffix") {
renderParameters.HeaderIDSuffix = ":" + ctx.DocumentId
}