From 039b4758ac4b6f9841a791bec9c53999349d8d71 Mon Sep 17 00:00:00 2001 From: Sam Date: Wed, 26 Jun 2013 20:51:43 +1000 Subject: [PATCH] fix 1.9.3 regression, [] does not work on OpenStruct there. --- app/models/post_action.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/models/post_action.rb b/app/models/post_action.rb index eb08c05c4df..fda896c896b 100644 --- a/app/models/post_action.rb +++ b/app/models/post_action.rb @@ -337,14 +337,14 @@ class PostAction < ActiveRecord::Base post_actions.each do |pa| post = post_lookup[pa.post_id] - post[:post_actions] ||= [] + post.post_actions ||= [] action = pa.attributes if (pa.related_post && pa.related_post.topic) action.merge!(topic_id: pa.related_post.topic_id, slug: pa.related_post.topic.slug, permalink: pa.related_post.topic.url) end - post[:post_actions] << action + post.post_actions << action users << pa.user_id end