redirect: use document.location.replace instead of location.href to

avoid storing old URL in browser history
This commit is contained in:
Kilian Cavalotti 2018-10-18 08:38:41 -07:00
parent 0c17ca3a52
commit dcf6c34284

View File

@ -22,7 +22,7 @@
{% if page.meta.redirect %} {% if page.meta.redirect %}
<script> <script>
location.href = '{{ page.meta.redirect }}') document.location.replace({{ page.meta.redirect }})
</script> </script>
<meta http-equiv="refresh" content="0; url={{ page.meta.redirect }}"/> <meta http-equiv="refresh" content="0; url={{ page.meta.redirect }}"/>
<link rel="canonical" href="{{ page.meta.redirect }} " /> <link rel="canonical" href="{{ page.meta.redirect }} " />