class Public::CommentsController < ApplicationController

	before_filter :auth_customer
	before_filter :check_enabled

	def create
		@comment = Comment.new(params.require(:comment).permit(:website, :pseudo, :email, :comment, :commentable_id, :commentable_type))
	
		

	
		if @comment.save
			commentable = @comment.commentable
			@comment_id = @comment.id
			@comment = Comment.new
			@comment.commentable = commentable

		end

	end

end
