Commit b63d529a authored by Dries's avatar Dries

- Patch #12515 by Goba: fixed problem with cookies not being set properly,...

- Patch #12515 by Goba: fixed problem with cookies not being set properly, causing users getting logged out.
parent bd6ae693
...@@ -807,11 +807,6 @@ function user_login($edit = array(), $msg = '') { ...@@ -807,11 +807,6 @@ function user_login($edit = array(), $msg = '') {
user_module_invoke('login', $edit, $user); user_module_invoke('login', $edit, $user);
// If the user wants to be remembered, set the proper cookie such
// that the session won't expire.
$path = preg_replace("/.+\/\/[^\/]+(.*)/", "\$1/", $base_url);
setcookie(session_name(), session_id(), FALSE, $path);
// Redirect the user to the page he logged on from. // Redirect the user to the page he logged on from.
drupal_goto($edit['destination']); drupal_goto($edit['destination']);
} }
......
...@@ -807,11 +807,6 @@ function user_login($edit = array(), $msg = '') { ...@@ -807,11 +807,6 @@ function user_login($edit = array(), $msg = '') {
user_module_invoke('login', $edit, $user); user_module_invoke('login', $edit, $user);
// If the user wants to be remembered, set the proper cookie such
// that the session won't expire.
$path = preg_replace("/.+\/\/[^\/]+(.*)/", "\$1/", $base_url);
setcookie(session_name(), session_id(), FALSE, $path);
// Redirect the user to the page he logged on from. // Redirect the user to the page he logged on from.
drupal_goto($edit['destination']); drupal_goto($edit['destination']);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment