Modeled from the (Facebook Javascript SDK), now with the facebook-node-sdk you can now easily write the same code and share between your server (nodejs) and the client (Facebook Javascript SDK).
Other
736
stars
250
forks
source link
Error Code on Login Not Correctly Represented in JSON Structure. #96
Note error_code. If I have named my structure, fb_response, I cannot get at this with fb_response["error_code"]. I have to use fb_response["error_code "], because an extra space comes back between the member name and colon.
When I log in to Facebook, and I get an error back, such as with an invalid id or token, I get the following structure back:
{ error_code : 2, token: 'abcdefghiii', token_secret: undefined, source_service: 'Facebook', source_service_id: '123456789', error_message: 'Invalid OAuth access token.', error: true }
Note error_code. If I have named my structure, fb_response, I cannot get at this with fb_response["error_code"]. I have to use fb_response["error_code "], because an extra space comes back between the member name and colon.