diff options
author | Kent Rogers <kar@cray.com> | 2010-05-12 23:29:58 -0700 |
---|---|---|
committer | Max Kanat-Alexander <mkanat@bugzilla.org> | 2010-05-12 23:29:58 -0700 |
commit | 34e9970696a7dd34bc21cea973d2ad3696440792 (patch) | |
tree | 93dac67b52960399e537ad5819923cb908b4a142 /Bugzilla | |
parent | 20ed8a92744b90c7b6b5eab19d0ed7e846100a5e (diff) | |
download | bugs-34e9970696a7dd34bc21cea973d2ad3696440792.tar bugs-34e9970696a7dd34bc21cea973d2ad3696440792.tar.gz bugs-34e9970696a7dd34bc21cea973d2ad3696440792.tar.bz2 bugs-34e9970696a7dd34bc21cea973d2ad3696440792.tar.xz bugs-34e9970696a7dd34bc21cea973d2ad3696440792.zip |
Bug 271913: Do not force the user to comment when adding Hours Worked
r=mkanat, a=mkanat
Diffstat (limited to 'Bugzilla')
-rw-r--r-- | Bugzilla/Bug.pm | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/Bugzilla/Bug.pm b/Bugzilla/Bug.pm index b9c64da7f..1b7753eff 100644 --- a/Bugzilla/Bug.pm +++ b/Bugzilla/Bug.pm @@ -2243,11 +2243,7 @@ sub add_comment { $comment = $self->_check_comment($comment); $params ||= {}; - if (exists $params->{work_time}) { - $params->{work_time} = $self->_check_work_time($params->{work_time}); - ThrowUserError('comment_required') - if $comment eq '' && $params->{work_time} != 0; - } + $params->{work_time} = $self->_check_work_time($params->{work_time}); if (exists $params->{type}) { $params->{type} = $self->_check_comment_type($params->{type}); } @@ -2257,7 +2253,7 @@ sub add_comment { } # XXX We really should check extra_data, too. - if ($comment eq '' && !($params->{type} || $params->{work_time})) { + if ($comment eq '' && !($params->{type} || abs($params->{work_time}))) { return; } |