This commit is contained in:
nilsding 2014-12-12 22:35:23 +01:00
parent c91fbe43b1
commit 23fc3009fe
2 changed files with 12 additions and 0 deletions

View File

@ -35,4 +35,14 @@ class ServicesController < ApplicationController
flash[:success] = 'Successfully removed service' flash[:success] = 'Successfully removed service'
redirect_to services_path redirect_to services_path
end end
private
def origin
request.env['omniauth.origin']
end
def omniauth_hash
request.env['omniauth.auth']
end
end end

View File

@ -1,4 +1,6 @@
class Service < ActiveRecord::Base class Service < ActiveRecord::Base
attr_accessor :provider, :info
belongs_to :user belongs_to :user
validates_uniqueness_of :uid, scope: :type validates_uniqueness_of :uid, scope: :type