Fine to let destroying something destroyed be a no-op

Would be an edge-casey race condition, but its possible
This commit is contained in:
David Heinemeier Hansson
2025-04-11 17:00:08 +02:00
parent 256d536009
commit 8a4a087a00
@@ -17,7 +17,7 @@ class Cards::Comments::ReactionsController < ApplicationController
def destroy
@reaction = @comment.reactions.find(params[:id])
@reaction.destroy!
@reaction.destroy
broadcast_remove
end