Do not forget to downcase the categories here as well

This commit is contained in:
Sylvain UTARD 2014-07-27 00:29:31 +02:00
parent 16dbe54560
commit 592630d48c
2 changed files with 2 additions and 2 deletions

View File

@ -160,7 +160,7 @@ module Jekyll
def process(name)
m, cats, date, slug, ext = *name.match(MATCHER)
self.categories ||= []
self.categories += (cats || '').split('/')
self.categories += (cats || '').downcase.split('/')
self.date = Time.parse(date)
self.slug = slug
self.ext = ext

View File

@ -85,7 +85,7 @@ class TestPost < Test::Unit::TestCase
post = Post.allocate
post.site = @site
post.process("cat2/cat3/2008-09-09-foo-bar.textile")
post.process("cat2/CAT3/2008-09-09-foo-bar.textile")
assert_equal 2, post.categories.size
assert_equal "cat2", post.categories[0]
assert_equal "cat3", post.categories[1]