mirror of
https://gitlab.archlinux.org/archlinux/aurweb.git
synced 2025-02-03 10:43:03 +01:00
pkgsubmit.php: Fix PHP notice for depends processing
A foreach() is run without verifying an uploaded package has any depends.
Fix the undefined index notice for packages uploaded with no depends.
Similar to commit 857de725d1
.
Signed-off-by: canyonknight <canyonknight@gmail.com>
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
This commit is contained in:
parent
e9ed60566e
commit
238695c402
1 changed files with 2 additions and 2 deletions
|
@ -390,8 +390,8 @@ if ($uid):
|
|||
}
|
||||
|
||||
# Update package depends
|
||||
$depends = explode(" ", $new_pkgbuild['depends']);
|
||||
if ($depends !== false) {
|
||||
if (!empty($new_pkgbuild['depends'])) {
|
||||
$depends = explode(" ", $new_pkgbuild['depends']);
|
||||
foreach ($depends as $dep) {
|
||||
$deppkgname = preg_replace("/(<|<=|=|>=|>).*/", "", $dep);
|
||||
$depcondition = str_replace($deppkgname, "", $dep);
|
||||
|
|
Loading…
Add table
Reference in a new issue