diff options
author | jocuri%softhome.net <> | 2004-01-31 09:12:08 +0100 |
---|---|---|
committer | jocuri%softhome.net <> | 2004-01-31 09:12:08 +0100 |
commit | 345f9df2f29d90a777051db3d34194ac04b8b637 (patch) | |
tree | 7724d113d13b92ecdf8b1cb0c32d5a28703f34b7 /post_bug.cgi | |
parent | 5f12f937db422fca2979115059d580ba8a91e6db (diff) | |
download | bugzilla-345f9df2f29d90a777051db3d34194ac04b8b637.tar.gz bugzilla-345f9df2f29d90a777051db3d34194ac04b8b637.tar.xz |
Patch for bug 213679: Implement a parameter that allows administrators to control whether blank comments are allowed when filling new bugs; code by Dave Swegen <dswegen@software.plasmon.com>; r=myk; a=myk.
Diffstat (limited to 'post_bug.cgi')
-rwxr-xr-x | post_bug.cgi | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/post_bug.cgi b/post_bug.cgi index 315ff3a99..dbc102d3e 100755 --- a/post_bug.cgi +++ b/post_bug.cgi @@ -76,6 +76,10 @@ my $format = GetFormat("bug/create/comment", $::FORM{'format'}, "txt"); $template->process($format->{'template'}, $vars, \$comment) || ThrowTemplateError($template->error()); +# Check that if required a description has been provided +if (Param("commentoncreate") && !trim($::FORM{'comment'})) { + ThrowUserError("description_required"); +} ValidateComment($comment); my $product = $::FORM{'product'}; |