From cd3e824bc156300f1de22110501282b2bc8d25b8 Mon Sep 17 00:00:00 2001 From: Pistos Date: Sat, 8 Oct 2011 22:59:44 -0400 Subject: [PATCH] Explicitly specify order of comments, since we cannot assume MySQL ordering (which is by id). --- app/views/comments/_comments.html.haml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/comments/_comments.html.haml b/app/views/comments/_comments.html.haml index b7df16c82..2acdfb71e 100644 --- a/app/views/comments/_comments.html.haml +++ b/app/views/comments/_comments.html.haml @@ -11,7 +11,7 @@ -if post.comments.size > 3 && !comments_expanded = render :partial => 'comments/comment', :collection => post.last_three_comments, :locals => {:post => post} -else - = render :partial => 'comments/comment', :collection => post.comments, :locals => {:post => post} + = render :partial => 'comments/comment', :collection => post.comments.order('created_at'), :locals => {:post => post} - unless commenting_disabled?(post) .new_comment_form_wrapper{:class => comment_form_wrapper_class(post)}