Commit 42f52759 authored by Carl Schwan's avatar Carl Schwan

Redirect to default language

parent 9cb797e7
......@@ -14,5 +14,12 @@
];
var errorEmoji = emojiArray[Math.floor(Math.random() * emojiArray.length)];
errorEmojiContainer.appendChild(document.createTextNode(errorEmoji));
let url = new Url(window.location.href);
let path = url.pathname;
if (new RegExp('^\/[a-z]{2}', 'i')) {
path = path.substr(3);
}
window.location.replace(url.hostname + path)
</script>
{{ end }}
\ No newline at end of file
{{ end }}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment