set user_type correct for comments
This commit is contained in:
@ -64,7 +64,7 @@ class CommentsController < ApplicationController
|
||||
# POST /comments
|
||||
# POST /comments.json
|
||||
def create
|
||||
@comment = Comment.new(comment_params.merge(user_type: 'InternalUser'))
|
||||
@comment = Comment.new(comment_params.merge(user_type: current_user.class.name))
|
||||
|
||||
respond_to do |format|
|
||||
if @comment.save
|
||||
|
Reference in New Issue
Block a user