Commit caca2a38 authored by lpsolit%gmail.com's avatar lpsolit%gmail.com

Bug 340609: Bug->check() should throw an error if no bug ID is passed - Patch by…

Bug 340609: Bug->check() should throw an error if no bug ID is passed - Patch by Fré©ric Buclin <LpSolit@gmail.com> r=bkor a=LpSolit
parent b8ec302b
...@@ -296,6 +296,8 @@ sub check { ...@@ -296,6 +296,8 @@ sub check {
my $class = shift; my $class = shift;
my ($id, $field) = @_; my ($id, $field) = @_;
ThrowUserError('improper_bug_id_field_value', { field => $field }) unless defined $id;
# Bugzilla::Bug throws lots of special errors, so we don't call # Bugzilla::Bug throws lots of special errors, so we don't call
# SUPER::check, we just call our new and do our own checks. # SUPER::check, we just call our new and do our own checks.
my $self = $class->new(trim($id)); my $self = $class->new(trim($id));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment