aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNoah Loomans <noahloomans@gmail.com>2018-05-19 09:42:32 +0000
committerNoah Loomans <noahloomans@gmail.com>2018-05-19 09:42:32 +0000
commit8fdea9620b6bdedfcbd93a109ff5eba20482668a (patch)
treea1515bb177ee86d1ef6151b658f9fc3b58ed5646
parent23b5e6f5b60c0a0ba543d363be2a6d1fe752fb8b (diff)
Ensure compatibility with jekyll 3.0.1
-rw-r--r--_plugins/relativize_url.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/_plugins/relativize_url.rb b/_plugins/relativize_url.rb
index b7df362..d419032 100644
--- a/_plugins/relativize_url.rb
+++ b/_plugins/relativize_url.rb
@@ -1,5 +1,9 @@
require 'pathname'
+def ensure_leading_slash(path)
+ path[0..0] == "/" ? path : "/#{path}"
+end
+
module Jekyll
module UrlRelativizer
def relativize_url(input)