You are here

function tokenauth_exit in Token authentication 7

Same name and namespace in other branches
  1. 5 tokenauth.module \tokenauth_exit()
  2. 6.2 tokenauth.module \tokenauth_exit()
  3. 6 tokenauth.module \tokenauth_exit()

Implements hook_exit().

Deliberately insure that this session will not be saved by sess_write(). Safety.

See also

user_logout

File

./tokenauth.module, line 134

Code

function tokenauth_exit() {
  global $user;
  if (isset($_SESSION['tokenauth_auth'])) {

    // Load the anonymous user
    $user = drupal_anonymous_user();
  }
}