This is line 256 of fb_example.module
if ($fbu = fb_facebook_user()) {
// The user has connected (as opposed to logged out). Let's redirect
// them to our 'welcome' page. Replace 'welcome' with the path you
// really want.
$url = url('welcome',
array('absolute' => TRUE, 'fb_canvas' => fb_is_canvas()));
// We return javascript to be evaluated by fb.js.
$return[] = "FB_JS.reload('$url');";
}
I am wanting to verify if the $fbu = fb_facebook_user() is meant to compare the values, or if it is meant to set the value of $fbu and if for some reason the operation returns false to not run the bit of code? I don't see that $fbu is used anywhere else in the function so it is a bit uncertain.
It looks like a common error, but I'm not certain what the side effects / testing of this have been...
Comments
Comment #1
Dave Cohen commentedThe logic is correct. It could read
Probably there was some time in the past I was using $fbu in that clause. But no longer.