Check comment length in the backend

Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
This commit is contained in:
Lukas Fleischer 2015-10-21 22:29:40 +02:00
parent 16765d5532
commit 9c70e10aeb
2 changed files with 5 additions and 6 deletions

View file

@ -330,6 +330,10 @@ function pkgbase_flag($base_ids, $comment) {
return array(false, __("You did not select any packages to flag."));
}
if (strlen($comment) < 3) {
return array(false, __("The selected packages have not been flagged, please enter a comment."));
}
$uid = uid_from_sid($_COOKIE['AURSID']);
$dbh = DB::connect();