Commit 9d68984b by Rocky Duan

default empty children array

parent 035d6f4c
......@@ -30,7 +30,7 @@ class Comment < ActiveRecord::Base
end
def to_hash
attributes.merge(:votes => {:up => votes_for, :down => votes_against, :plusminus => plusminus})
attributes.merge(:votes => {:up => votes_for, :down => votes_against, :plusminus => plusminus}, :children => [])
end
def to_json
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment