Skip to content

Commit

Permalink
Remove addr. from FB request in #get_data.Otherwise will get error(#100)
Browse files Browse the repository at this point in the history
  • Loading branch information
aligit committed Dec 24, 2015
1 parent 2a5dd52 commit 5dbf734
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion examples/server/ruby/app/models/oauth/facebook.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ class Facebook < Oauth::Base
DATA_URL = 'https://graph.facebook.com/v2.5/me'

def get_data
response = @client.get(DATA_URL, access_token: @access_token, fields: 'first_name, last_name, email, gender, about, address, link, website, picture')
response = @client.get(DATA_URL, access_token: @access_token, fields: 'first_name, last_name, email, gender, about, link, website, picture')
@data = JSON.parse(response.body).with_indifferent_access
@data['image_url'] = @data['picture']['data']['url'] if @data['picture'].present?
@uid = @data[:id] ||= @data[:sub]
Expand Down

0 comments on commit 5dbf734

Please sign in to comment.