You are here

function simple_ldap_sso_user_logout in Simple LDAP 7

Same name and namespace in other branches
  1. 7.2 simple_ldap_sso/simple_ldap_sso.module \simple_ldap_sso_user_logout()

Implements hook_user_logout().

1 call to simple_ldap_sso_user_logout()
simple_ldap_sso_abort in simple_ldap_sso/simple_ldap_sso.inc
Abort the SSO. Logs a watchdog alert, and destroys the session.

File

simple_ldap_sso/simple_ldap_sso.module, line 165

Code

function simple_ldap_sso_user_logout(stdClass $account) {

  // If this is user 1, or the module isn't configured, just return.
  if ($account->uid == 1 || !simple_ldap_sso_configured()) {
    return;
  }
  simple_ldap_sso_delete_cookie();
  simple_ldap_sso_ldap_delete_sid($account->name);
}