Friday, 7 June 2013

Login dialog popup not working within app when not logged onto Facebook

Came across a weird problem today with a Facebook app we're building. When viewing the app in its canvas or a page tab environment, clicking a button that should trigger the javascript SDK login popup actually resulted in brief flash of a waiting animation and then nothing.

Some investigation revealed this bug logged by Facebook but only replicated by 9 people (as of today) in about three weeks. Sure enough, checking an existing live Facebook app which I built a few months ago, and which gets about 1000 users a day, displayed the same behaviour - you couldn't use the app if you weren't alreay logged in.

It's interesting that Facebook appear to have broken something quite critical but seem to have done little to fix it, and it's also interesting how so few devs have contributed a replication report to the bug. Surely 1000's of apps are affected by this?

I think what this shows us, and the fact that I've had no complaints about accessing my other live app that are nonetheless affected by this bug, is how few users visit a Facebook app without actually being logged in.

Anyway, a temporary and quick fix while this remains a problem is to simply use javascript to detect the scenario of being in a canvas or a tab, and the user being logged out, and instead of prompting the broken Fbook login popup simply alert the user that they need to be logged in. This seems better than nothing happening.

In the meantime subscribe to the bug and when you get notice that its fixed then put your code back to how it was.

No comments:

Post a Comment

Comments are moderated, so you'll have to wait a little bit before they appear!