Facebook.login callback fires multiple times
I'm using the AS3 SDK and running into a weird issue. I do something like the following:
Facebook.init(MY_APP_ID, someHandler);
This works ok. At some later point as a result of a user clicking a button in a swf, I do:
Facebook.login(someOtherHandler, {perms:"offline_access,publish_stream"});
Following the user login/approval in the FB popup window, the "someOtherHandler" method is called, but the problem is it is getting called many times - like upwards of 150. In Firefox this is annoying but still works, and I'm then able to make other calls to the API (lookup their account info, post to their wall, etc.). In IE however, this typically leads to a stack overflow. And honestly, even in Firefox this isn't something I want to live with.
If I do a barebones "hello world" type example to try to reproduce the problem I can't; there the callback only fires the expected single time. I'm trying to isolate what could be causing the callback to be called again and again but the system I'm integrating this into is quite large and so it's taking a very long time. That's also why I'm not posting the real cod开发者_Python百科e which I know will make it harder for anyone else to help out, but I'm hoping someone's been down this general road before. Thx.
(EDIT - I have verified that Facebook.login is in fact only being called a single time)
精彩评论