Skip to content

Instantly share code, notes, and snippets.

@drKreso
Created November 3, 2018 11:12
Show Gist options
  • Save drKreso/a2664ebeafc55e1e5af7293e670d26a0 to your computer and use it in GitHub Desktop.
Save drKreso/a2664ebeafc55e1e5af7293e670d26a0 to your computer and use it in GitHub Desktop.
# config/initializers/oauth.rb
Rails.application.config.middleware.use OmniAuth::Builder do
provider :facebook,
ENV['FACEBOOK_APP_ID'],
ENV['FACEBOOK_SECRET_ID'],
scope: 'email',
info_fields: 'email',
auth_type: 'rerequest'
configure do |config|
config.path_prefix = '/users/auth'
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment