summaryrefslogtreecommitdiffstats
path: root/web/lib/pkgreqfuncs.inc.php
diff options
context:
space:
mode:
Diffstat (limited to 'web/lib/pkgreqfuncs.inc.php')
-rw-r--r--web/lib/pkgreqfuncs.inc.php4
1 files changed, 4 insertions, 0 deletions
diff --git a/web/lib/pkgreqfuncs.inc.php b/web/lib/pkgreqfuncs.inc.php
index 5b86eaaf..41d1515b 100644
--- a/web/lib/pkgreqfuncs.inc.php
+++ b/web/lib/pkgreqfuncs.inc.php
@@ -95,6 +95,10 @@ function pkgreq_file($ids, $type, $merge_into, $comments) {
return array(false, __("Invalid name: only lowercase letters are allowed."));
}
+ if (!empty($merge_into) && !pkgbase_from_name($merge_into)) {
+ return array(false, __("Cannot find package to merge votes and comments into."));
+ }
+
if (empty($comments)) {
return array(false, __("The comment field must not be empty."));
}