My Sessions Controller
我的会话控制器
def create
auth = request.env["omniauth.auth"]
person=Person.find_by_provider_and_uid(auth.provider,auth.uid) || Person.create_with_omniauth(auth)
session[:user_id] = person.id
redirect_to root_path
end
def failure
redirect_to signin_path , alert: "Authentication failed, please try again."
end
def create