From e8a839d5f667850ddf3a75114c01ba66b9c76d0c Mon Sep 17 00:00:00 2001 From: David Heinemeier Hansson Date: Sat, 12 Apr 2025 11:47:08 +0200 Subject: [PATCH] We have a callback dependency to do this actually --- app/controllers/cards/comments_controller.rb | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/app/controllers/cards/comments_controller.rb b/app/controllers/cards/comments_controller.rb index 35f8e13e7..33437eb24 100644 --- a/app/controllers/cards/comments_controller.rb +++ b/app/controllers/cards/comments_controller.rb @@ -19,14 +19,13 @@ class Cards::CommentsController < ApplicationController end def destroy - @message.destroy + @comment.destroy redirect_to @card end private def set_comment @comment = Comment.belonging_to_card(@card).find(params[:id]) - @message = @comment.message end def ensure_creatorship