summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYehonal <yehonal.azeroth@gmail.com>2017-05-07 23:43:02 +0200
committerGitHub <noreply@github.com>2017-05-07 23:43:02 +0200
commit41dfdbe20995d348d11960034e4c3044d19cb6ce (patch)
tree6ba5570797303a8e69eacf8eae32337997cd246d
parente83f4836bfa13fa12bc6d48d810e6afa25803e77 (diff)
downloadwiki-41dfdbe20995d348d11960034e4c3044d19cb6ce.tar.gz
wiki-41dfdbe20995d348d11960034e4c3044d19cb6ce.tar.bz2
wiki-41dfdbe20995d348d11960034e4c3044d19cb6ce.zip
trying to fix edit when index is not in root
-rw-r--r--_layouts/default.html3
1 files changed, 2 insertions, 1 deletions
diff --git a/_layouts/default.html b/_layouts/default.html
index c68fad6..f7c5cf1 100644
--- a/_layouts/default.html
+++ b/_layouts/default.html
@@ -1,7 +1,8 @@
<!doctype html>
<html>
<head>
- {% capture url %}{% if page.url == "/" %}/index.html{% else %}{{ page.url | default: 'index.html' }}{% endif %}{% endcapture %}
+ {% capture lchar %}{page.url | slice: -1, 1}{% endcapture %}
+ {% capture url %}{% if lchar == "/" %}/index.html{% else %}{{ page.url | default: 'index.html' }}{% endif %}{% endcapture %}
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="chrome=1">
<title>{{ site.title | default: site.github.repository_name }} by {{ site.github.owner_name }}</title>