Remove "Account has already been associated with an account" message and auto redirect
| Project: | Facebook - Auth |
| Version: | 6.x-1.x-dev |
| Component: | Code |
| Category: | feature request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | active |
Jump to:
Can we perhaps remove the need to display a page with the message "Account has already been associated with an account" ?
I'm linking to pages on a Drupal site using the url /facebook?destination=node/123 to ensure that any visitor from Facebook gets auth logged in straight away. This works great!
However, if you then click another link from facebook after already being auth'd the message above greets the same user coming back. Would it not be better to just redirect the re-visiting user to their final destination url and forget the message?
Something like the following in function facebook_auth() :
// user should be authenticated by Facebook now
$account = user_external_load($u .'@facebook');
if ($user->uid && $account) {
//return t('Account has already been associated with an account.');
drupal_goto();
}This could be extended to check if there is no redirection variable specified then just show the message.

#1
I'd be willing to accept a patch for this.