tpl/tplimpl: Replace deprecated .GetParam usage
authorBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>
Tue, 9 Apr 2019 14:39:12 +0000 (16:39 +0200)
committerBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>
Tue, 9 Apr 2019 14:39:12 +0000 (16:39 +0200)
Fixes #5834

tpl/tplimpl/embedded/templates.autogen.go
tpl/tplimpl/embedded/templates/disqus.html

index 89078350e816a9396a2fdff631e573f27ea1713d..164f3b92758b16829875f0277d6229cd7c9f8322 100644 (file)
@@ -90,9 +90,9 @@ var EmbeddedTemplates = [][2]string{
 {{ if .Site.DisqusShortname }}<div id="disqus_thread"></div>
 <script type="application/javascript">
     var disqus_config = function () {
-    {{with .GetParam "disqus_identifier" }}this.page.identifier = '{{ . }}';{{end}}
-    {{with .GetParam "disqus_title" }}this.page.title = '{{ . }}';{{end}}
-    {{with .GetParam "disqus_url" }}this.page.url = '{{ . | html  }}';{{end}}
+    {{with .Params.disqus_identifier }}this.page.identifier = '{{ . }}';{{end}}
+    {{with .Params.disqus_title }}this.page.title = '{{ . }}';{{end}}
+    {{with .Params.disqus_url }}this.page.url = '{{ . | html  }}';{{end}}
     };
     (function() {
         if (["localhost", "127.0.0.1"].indexOf(window.location.hostname) != -1) {
index ab51bb5c0b70fbaa8f54843bc05b67ad9bc71e27..fed512ff0822901a87b78c2407db73a8f32e8a3f 100644 (file)
@@ -3,9 +3,9 @@
 {{ if .Site.DisqusShortname }}<div id="disqus_thread"></div>
 <script type="application/javascript">
     var disqus_config = function () {
-    {{with .GetParam "disqus_identifier" }}this.page.identifier = '{{ . }}';{{end}}
-    {{with .GetParam "disqus_title" }}this.page.title = '{{ . }}';{{end}}
-    {{with .GetParam "disqus_url" }}this.page.url = '{{ . | html  }}';{{end}}
+    {{with .Params.disqus_identifier }}this.page.identifier = '{{ . }}';{{end}}
+    {{with .Params.disqus_title }}this.page.title = '{{ . }}';{{end}}
+    {{with .Params.disqus_url }}this.page.url = '{{ . | html  }}';{{end}}
     };
     (function() {
         if (["localhost", "127.0.0.1"].indexOf(window.location.hostname) != -1) {