Send "N comments" links to the comments anchors.

We have to call post.save in the posts/index specs, because post_path
fails unless the post has been persisted (and hence had its slug
generated). I think. That fixed the failing tests, anyway.
This commit is contained in:
Miles Gould committed 2013-02-27 15:39:42 +00:00
1 parent e7a1beb323
commit e470cf7358
3 files changed
+7 -8

No files matched your search

+2 -1
View File
@@ -24,7 +24,8 @@
- unless defined?(hide_comments)
.post-comments
%ul.inline
%li.first= link_to pluralize(post.comments.count, "comment"), post
%li.first= link_to pluralize(post.comments.count, "comment"),
post_path(post, :anchor => 'comments')
-if can? :create, Comment
%li= link_to "Reply", new_comment_path(:post_id => post.id)
%li= link_to "Permalink", post