From a374c3d589d8b05b7efac81057ae9e928b547c35 Mon Sep 17 00:00:00 2001 From: Lorin Werthen Date: Thu, 9 Feb 2017 02:36:29 +0100 Subject: [PATCH] even less lines wow --- lib/helpers/preprocess.rb | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/lib/helpers/preprocess.rb b/lib/helpers/preprocess.rb index d7a4121..0c3a0a0 100644 --- a/lib/helpers/preprocess.rb +++ b/lib/helpers/preprocess.rb @@ -8,12 +8,10 @@ module PreprocessHelper def update_blog_attributes @items.find_all('/blog/**/*').each do |i| - year_str = i.identifier.to_s[/\d\d-\d\d/] - attr_hash = { # Tag all posts with article (for Blogging helper) kind: 'article', - academic_year: year_str, + academic_year: i.identifier.to_s[/\d\d-\d\d/], created_at: Date.parse(i[:created_at]) }