Do not forget to downcase the categories here as well
This commit is contained in:
parent
16dbe54560
commit
592630d48c
|
@ -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
|
||||
|
|
|
@ -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]
|
||||
|
|
Loading…
Reference in New Issue