daogr / facebook-actionscript-api

Automatically exported from code.google.com/p/facebook-actionscript-api
0 stars 0 forks source link

Should returned errors hit the resultCallback passing a failed object instead of success? #275

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Make an FQL call with the following query: "SELECT no_such_permission FROM 
permissions WHERE uid = me()" (just a test that will force an error).
2. Receive an error_code and error_msg in the callback's success response.

Should handleDataLoad in FacebookRequest look for an error_code in the response 
and change the _success property of the request object to false instead of true?

Or should failed data be reserved for data that cannot be properly decoded by 
the JSON class (which is how it is currently handled)?

Original issue reported on code.google.com by yourpalm...@gmail.com on 21 Mar 2011 at 4:21

GoogleCodeExporter commented 8 years ago
Thanks for the catch! This was fixed in the later versions of the API. FQL 
errors are detected in the handleRequestLoad method in AbstractFacebook so it 
will return a fail object in the callback for the fql call.

Original comment by edwar...@gmail.com on 13 Oct 2011 at 7:35