I am setting up a rails application (4.1.10) using Devise. I am adding the OmniAuth Facebook integration using this devise guide : https://github.com/plataformatec/devise/wiki/OmniAuth:-Overview
I think I have set up everything that I should ( I am aware I should put the app_id and secret into ENV variables - which I will move onto once this works) However when I click my sign into facebook link I get an error:
https://www.facebook.com/dialog/oauth?client_id=&display=popup&redirect_uri=http%3A%2F%2Fwww.clazzoo.com%2Fusers%2Fauth%2Ffacebook%2Fcallback&response_type=code&scope=email%2Cuser_birthday%2Cread_stream&state=b43008b5d8e714e91ac37b4410f7758655efecbca7bfe98e
Warning
The parameter app_id is required
The config is here:
# Use this hook to configure devise mailer, warden hooks and so forth.
# Many of these configuration options can be set straight in your model.
Devise.setup do |config|
...
...
config.omniauth :facebook, "1602932433319776", "7221cf917c6e55ba68c8e81145994481",
:scope => 'email,user_birthday,read_stream',
:display => 'popup'
config.omniauth :stripe_connect,
Settings.stripeConnectClientID,
Settings.stripeSecretKey,
:scope => 'read_write',
:stripe_landing => 'register'
end
The User model has the omniauthable set:
class User < ActiveRecord::Base
# Include default devise modules. Others available are:
# :confirmable, :lockable, :timeoutable and :omniauthable
devise :database_authenticatable, :registerable,
:recoverable, :rememberable, :trackable, :validatable, :confirmable,
:omniauthable, :omniauth_providers => [:facebook]
So why when I click my link does it miss out the appropriate ID?
I'm not sure what was broken - turns out recommiting my code to heroku and doing a heroku restart fixed it. Simples ;)