mirror of
https://gitlab.archlinux.org/archlinux/aurweb.git
synced 2025-02-03 09:43:03 +00:00
Require DB handle for most user account functions
This affects login the most, where we save about 4 calls to db_connect() by passing a single handle into functions where necessary. Signed-off-by: Dan McGee <dan@archlinux.org> Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
This commit is contained in:
parent
8dc7b37909
commit
e6ecdcc835
2 changed files with 15 additions and 26 deletions
|
@ -17,9 +17,8 @@ if (isset($_COOKIE["AURSID"])) {
|
|||
# setting expiration to 1 means '1 second after midnight January 1, 1970'
|
||||
setcookie("AURSID", "", 1, "/", null, !empty($_SERVER['HTTPS']), true);
|
||||
unset($_COOKIE['AURSID']);
|
||||
clear_expired_sessions($dbh);
|
||||
}
|
||||
|
||||
clear_expired_sessions();
|
||||
|
||||
header('Location: index.php');
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue