Skip to content

Commit

Permalink
Merge pull request #4 from docunext/master
Browse files Browse the repository at this point in the history
I kept getting can't convert date to string errors
  • Loading branch information
tdreyno committed Oct 31, 2011
2 parents 5163aff + c2b5065 commit eaf4e7a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/middleman-blog/feature.rb
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ def registered(app)
articles = Dir[articles_glob].map do |article|
template_content = File.read(article)
data, content = app.parse_front_matter(template_content)
data["date"] = Date.parse(data["date"])
data["date"] = Date.parse("#{data['date']}")

data["raw"] = content
data["url"] = article.gsub(app.views, "").split(".html").first + ".html"
Expand Down Expand Up @@ -117,7 +117,7 @@ def blog_title
end

def current_article_date
DateTime.parse(current_article_metadata.date)
DateTime.parse("#{current_article_metadata.date}")
end

def current_article_title
Expand Down

0 comments on commit eaf4e7a

Please sign in to comment.