mirror of
https://gitlab.archlinux.org/archlinux/aurweb.git
synced 2025-02-03 10:43:03 +01:00
index.php: Fix undefined variable notice
Spotted when browsing the package details page while being logged out. Reported-by: canyonknight <canyonknight@gmail.com> Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
This commit is contained in:
parent
0afe82f87c
commit
3d4cb66aed
1 changed files with 4 additions and 1 deletions
|
@ -42,7 +42,10 @@ if (isset($tokens[1]) && '/' . $tokens[1] == get_pkg_route()) {
|
|||
break;
|
||||
}
|
||||
|
||||
$_POST['token'] = $_COOKIE['AURSID'];
|
||||
if (isset($_COOKIE['AURSID'])) {
|
||||
$_POST['token'] = $_COOKIE['AURSID'];
|
||||
}
|
||||
|
||||
$_POST['IDs'] = array(pkgid_from_name($tokens[2]) => '1');
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue