get first_name and last_name fields from facebook omniauth
After some fiddling around i found the solution. Now i think we have to explicitly require the fields we require. For me the fix is just to add first_name
and last_name
to facebook
.
In my initializers
i added first_name
and last_name
to info fields
.
info_fields: 'email, first_name, last_name'
Update
My full config file will look like this now
config.omniauth :facebook, ENV["FACEBOOK_APP_ID"], ENV["FACEBOOK_SECRET"], scope: 'email', info_fields: 'email, first_name, last_name'