mirror of
https://github.com/torrentpier/torrentpier
synced 2025-08-21 22:03:49 -07:00
Fixed broken reset autologin (#825)
This commit is contained in:
parent
a9e0a975dc
commit
7c49ed0755
1 changed files with 2 additions and 4 deletions
|
@ -335,6 +335,7 @@ class User
|
||||||
*/
|
*/
|
||||||
public function session_end(bool $update_lastvisit = false, bool $set_cookie = true)
|
public function session_end(bool $update_lastvisit = false, bool $set_cookie = true)
|
||||||
{
|
{
|
||||||
|
Sessions::cache_rm_userdata($this->data);
|
||||||
DB()->query("
|
DB()->query("
|
||||||
DELETE FROM " . BB_SESSIONS . "
|
DELETE FROM " . BB_SESSIONS . "
|
||||||
WHERE session_id = '{$this->data['session_id']}'
|
WHERE session_id = '{$this->data['session_id']}'
|
||||||
|
@ -356,10 +357,7 @@ class User
|
||||||
if (isset($_REQUEST['reset_autologin'])) {
|
if (isset($_REQUEST['reset_autologin'])) {
|
||||||
$this->create_autologin_id($this->data, false);
|
$this->create_autologin_id($this->data, false);
|
||||||
|
|
||||||
DB()->query("
|
Sessions::delete_user_sessions($this->data['user_id']);
|
||||||
DELETE FROM " . BB_SESSIONS . "
|
|
||||||
WHERE session_user_id = '{$this->data['user_id']}'
|
|
||||||
");
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue