From 3d4cb66aed66313f97c942faa0dc7a4df50bfff2 Mon Sep 17 00:00:00 2001 From: Lukas Fleischer Date: Tue, 18 Sep 2012 13:21:29 +0200 Subject: index.php: Fix undefined variable notice Spotted when browsing the package details page while being logged out. Reported-by: canyonknight Signed-off-by: Lukas Fleischer --- web/html/index.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'web/html/index.php') diff --git a/web/html/index.php b/web/html/index.php index 70698a4..2d80a94 100644 --- a/web/html/index.php +++ b/web/html/index.php @@ -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'); } } -- cgit v1.2.3-54-g00ecf