diff options
author | lpsolit%gmail.com <> | 2008-09-22 04:54:33 +0200 |
---|---|---|
committer | lpsolit%gmail.com <> | 2008-09-22 04:54:33 +0200 |
commit | caca2a3863097103e788766c23e74c58b9fff2a0 (patch) | |
tree | bbf2a36a8379adc9316f61352f48e16d8b560cd0 /Bugzilla | |
parent | b8ec302b3a99b54f5838e497adb1cabe3f2f15dd (diff) | |
download | bugzilla-caca2a3863097103e788766c23e74c58b9fff2a0.tar.gz bugzilla-caca2a3863097103e788766c23e74c58b9fff2a0.tar.xz |
Bug 340609: Bug->check() should throw an error if no bug ID is passed - Patch by Frédéric Buclin <LpSolit@gmail.com> r=bkor a=LpSolit
Diffstat (limited to 'Bugzilla')
-rw-r--r-- | Bugzilla/Bug.pm | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Bugzilla/Bug.pm b/Bugzilla/Bug.pm index 6f22d967c..1d12ee2cf 100644 --- a/Bugzilla/Bug.pm +++ b/Bugzilla/Bug.pm @@ -296,6 +296,8 @@ sub check { my $class = shift; 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 # SUPER::check, we just call our new and do our own checks. my $self = $class->new(trim($id)); |