private
# Use callbacks to share common setup or constraints between actions.
def set_commentable
@commentable = Post.find(params[:id])
end
# def set_post
# @post = Post.find(params[:id])
# end
# Never trust parameters from the scary internet, only allow the white list through.
def post_params
params.require(:post).permit(:content, :user_id)
end