fix google analytics if else condition

pull/1/head
Robert Austin 2018-12-09 20:56:24 +10:00
parent f648f84244
commit 102c3611e0
2 changed files with 3 additions and 3 deletions

View File

@ -28,4 +28,4 @@ defaults:
sass:
style: compact # possible values: nested expanded compact compressed
google_analytics_id: ""
google_analytics_id: null

View File

@ -1,4 +1,4 @@
{{ if site.google_analytics_id }}
{% if site.google_analytics_id %}
<!-- Global site tag (gtag.js) - Google Analytics -->
<script async src="https://www.googletagmanager.com/gtag/js?id={{ site.google_analytics_id }}"></script>
<script>
@ -8,4 +8,4 @@
gtag('config', '{{ site.google_analytics_id }}');
</script>
{{ end }}
{% endif %}