comment! -> comment
This commit is contained in:
@@ -2,7 +2,7 @@ class CommentsController < ApplicationController
|
||||
include BubbleScoped, BucketScoped
|
||||
|
||||
def create
|
||||
@bubble.comment! params.require(:comment).expect(:body)
|
||||
@bubble.comment params.require(:comment).expect(:body)
|
||||
redirect_to @bubble
|
||||
end
|
||||
end
|
||||
|
||||
@@ -7,7 +7,7 @@ module Bubble::Commentable
|
||||
scope :ordered_by_comments, -> { left_joins(:comments).group(:id).order("COUNT(comments.id) DESC") }
|
||||
end
|
||||
|
||||
def comment!(body)
|
||||
def comment(body)
|
||||
thread_entries.create! threadable: Comment.new(body: body, bubble: self)
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user