You are here

function hybridauth_user in HybridAuth Social Login 6.2

Implements hook_user().

File

./hybridauth.module, line 131
Main file for the HybridAuth module.

Code

function hybridauth_user($op, &$edit, &$account, $category = NULL) {
  if ($op == 'login') {
    _hybridauth_session_sync_data($account->uid);
  }
  elseif ($op == 'logout') {

    //session is already destroyed - so no sense to check anything here
  }
  elseif ($op == 'delete') {
    _hybridauth_identity_delete_by_uid($account->uid);
    _hybridauth_session_delete_by_uid($account->uid);
  }
}