diff options
Diffstat (limited to 'modules/user/user.module')
-rw-r--r-- | modules/user/user.module | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/modules/user/user.module b/modules/user/user.module index af603cd75..6bfd825b9 100644 --- a/modules/user/user.module +++ b/modules/user/user.module @@ -956,7 +956,9 @@ function user_logout() { // Destroy the current session: session_destroy(); module_invoke_all('user', 'logout', NULL, $user); - unset($user); + + // We have to use $GLOBALS to unset a global variable: + unset($GLOBALS['user']); drupal_goto(); } |