mirror of
https://github.com/TrezOne/congo-hindi-gujarati.git
synced 2026-06-15 04:52:55 -04:00
🔀 Merge pull request #1073 from sudomateo/push-psstlwtvukry
layouts: correctly check for template existence
This commit is contained in:
@@ -1,9 +1,9 @@
|
||||
{{ $jsHome := resources.Get "js/home.js" | resources.Minify | resources.Fingerprint "sha512" }}
|
||||
<div id="page">
|
||||
{{ partial "partials/home/page.html" . }}
|
||||
{{ partial "home/page.html" . }}
|
||||
</div>
|
||||
<div id="profile" class="hidden h-full">
|
||||
{{ partial "partials/home/profile.html" . }}
|
||||
{{ partial "home/profile.html" . }}
|
||||
</div>
|
||||
<script
|
||||
defer
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
>
|
||||
</div>
|
||||
{{ $header := print "header/" .Site.Params.header.layout ".html" }}
|
||||
{{ if templates.Exists $header }}
|
||||
{{ if templates.Exists ( printf "partials/%s" $header) }}
|
||||
{{ partial $header . }}
|
||||
{{ else }}
|
||||
{{ partial "header/basic.html" . }}
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
{{ define "main" }}
|
||||
{{ $partial := print "home/" .Site.Params.homepage.layout ".html" }}
|
||||
{{ if templates.Exists $partial }}
|
||||
{{ if templates.Exists ( printf "partials/%s" $partial) }}
|
||||
{{ partial $partial . }}
|
||||
{{ else }}
|
||||
{{ partial "home/page.html" . }}
|
||||
|
||||
Reference in New Issue
Block a user