From 84a7fc625d939a45014cc7b0a64ea6d2782fda63 Mon Sep 17 00:00:00 2001 From: Paul McKissock Date: Mon, 1 Jul 2024 16:01:46 -0400 Subject: [PATCH] [#11] Changed @comment to comment --- app/views/comments/show.html.erb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/views/comments/show.html.erb b/app/views/comments/show.html.erb index 9130a3f..23f67aa 100644 --- a/app/views/comments/show.html.erb +++ b/app/views/comments/show.html.erb @@ -4,8 +4,8 @@ Posted on <%= comment.created_at.strftime("%B %d, %Y at %I:%M %p") %> - Score: <%= comment.score %> <% user_vote = @user_votes[comment.id] %> - <%= button_to "Upvote", upvote_article_comment_path(comment), method: :post, class: "btn btn-sm upvote-button", data: { votable_type: 'Comment', votable_id: @comment.id, article_id: @comment.article.id } %> - <%= button_to "Downvote", downvote_article_comment_path(comment), method: :post, method: :post, class: "btn btn-sm downvote-button", data: { votable_type: 'Comment', votable_id: @comment.id, article_id: @comment.article.id } %> + <%= button_to "Upvote", upvote_article_comment_path(comment), method: :post, class: "btn btn-sm upvote-button", data: { votable_type: 'Comment', votable_id: comment.id, article_id: comment.article.id } %> + <%= button_to "Downvote", downvote_article_comment_path(comment), method: :post, method: :post, class: "btn btn-sm downvote-button", data: { votable_type: 'Comment', votable_id: comment.id, article_id: comment.article.id } %>

Replies