Sha256: e2ffbd48a3e4d4c142763a849801e0de11c27189899f7efcf6c89b361f5ab642
Contents?: true
Size: 319 Bytes
Versions: 2
Compression:
Stored size: 319 Bytes
Contents
module IdentityClient class SessionsController < ApplicationController def create auth = request.env["omniauth.auth"] user = User.find_by_provider_and_uid(auth["provider"], auth["uid"].to_s) || User.create_with_omniauth(auth) session[:user_id] = user.id redirect_to '/' end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
identity_client-0.1.2 | app/controllers/identity_client/sessions_controller.rb |
identity_client-0.1.1 | app/controllers/identity_client/sessions_controller.rb |