diff options
author | Philip Arndt <parndt@gmail.com> | 2010-11-23 09:34:11 +1300 |
---|---|---|
committer | Philip Arndt <parndt@gmail.com> | 2010-11-23 09:34:11 +1300 |
commit | 97101633ca5f0a94560d18adc0df41ca8f60eed7 (patch) | |
tree | c2414815b5476c3982647095af1625d459506af6 /app/helpers | |
parent | 8b1fd448316a69d4849ff47d9948364dbbbc4db1 (diff) | |
download | refinerycms-blog-97101633ca5f0a94560d18adc0df41ca8f60eed7.tar.gz refinerycms-blog-97101633ca5f0a94560d18adc0df41ca8f60eed7.tar.bz2 refinerycms-blog-97101633ca5f0a94560d18adc0df41ca8f60eed7.zip |
Consistent whitespace.
Diffstat (limited to 'app/helpers')
-rw-r--r-- | app/helpers/blog_posts_helper.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/app/helpers/blog_posts_helper.rb b/app/helpers/blog_posts_helper.rb index a74ec33..e690a51 100644 --- a/app/helpers/blog_posts_helper.rb +++ b/app/helpers/blog_posts_helper.rb @@ -4,10 +4,10 @@ module BlogPostsHelper return nil if posts.blank? html = '<section id="blog_archive_list"><h1>Archives</h1><nav>' links = [] - + posts.each do |e| links << e.published_at.strftime('%m/%Y') - end + end links.uniq! links.each do |l| year = l.split('/')[1] @@ -19,7 +19,7 @@ module BlogPostsHelper html += '</nav></section>' html.html_safe end - + def next_or_previous?(post) post.next.present? or post.prev.present? end |