]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 340609: ValidateBugId() should throw an error if no bug ID is passed - Patch...
authorlpsolit%gmail.com <>
Mon, 22 Sep 2008 02:57:11 +0000 (02:57 +0000)
committerlpsolit%gmail.com <>
Mon, 22 Sep 2008 02:57:11 +0000 (02:57 +0000)
Bugzilla/Bug.pm

index ffae17895f98947985e555f1090c7704622fa491..6ca9df3baaa6fcabc61f4cd491a9a3794e2c7fa5 100644 (file)
@@ -3303,6 +3303,8 @@ sub ValidateBugID {
     my $dbh = Bugzilla->dbh;
     my $user = Bugzilla->user;
 
+    ThrowUserError('improper_bug_id_field_value', { field => $field }) unless defined $id;
+
     # Get rid of leading '#' (number) mark, if present.
     $id =~ s/^\s*#//;
     # Remove whitespace