summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLukas Fleischer <lfleischer@archlinux.org>2015-10-03 11:15:33 +0200
committerLukas Fleischer <lfleischer@archlinux.org>2015-10-03 11:15:53 +0200
commitd0f8b285e4b87743bc6795dac6a7b4875649aed6 (patch)
tree5f61b76b04b8342f7c8d9d499e39e63bcc462e3f
parentd18a9638c6212eeb29cd52ab312ea716be4179cc (diff)
downloadaurweb-d0f8b285e4b87743bc6795dac6a7b4875649aed6.tar.xz
Fix a PHP "Undefined index" notice
Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
-rw-r--r--web/html/packages.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/web/html/packages.php b/web/html/packages.php
index 38a2e29..1b89278 100644
--- a/web/html/packages.php
+++ b/web/html/packages.php
@@ -21,7 +21,11 @@ if (!isset($pkgid) || !isset($pkgname)) {
$details = array();
if (isset($pkgid)) {
$details = pkg_get_details($pkgid);
- $pkgname = $details['Name'];
+ if (isset($details['Name'])) {
+ $pkgname = $details['Name'];
+ } else {
+ $pkgname = null;
+ }
} else {
unset($pkgname);
}