]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Fix some nits that I forgot to fix on checkin for bug 474715.
authormkanat%bugzilla.org <>
Fri, 23 Jan 2009 03:27:45 +0000 (03:27 +0000)
committermkanat%bugzilla.org <>
Fri, 23 Jan 2009 03:27:45 +0000 (03:27 +0000)
Bugzilla/Object.pm
Bugzilla/WebService/Bug.pm

index 75e04f2e796c3d7930726b046f7658ad6da9642e..adc96fa503a871375e72c8e65901fc67efeeb659 100644 (file)
@@ -168,7 +168,6 @@ sub match {
             next;
         }
         elsif ( $field eq 'WHERE' ) {
-            next unless $value;
             # the WHERE value is a hashref where the keys are
             # "column_name operator ?" and values are the placeholder's
             # value.
@@ -662,7 +661,7 @@ clauses to the underlying query. Its value is expected to a hash
 reference whose keys are the columns, operators and placeholders, and the 
 values are the placeholders' bind value. For example:
 
- WHERE => {'some_column >= ?' => $some_value }
+ WHERE => { 'some_column >= ?' => $some_value }
     
 would constrain the query to only those objects in the table whose
 'some_column' column has a value greater than or equal to $some_value.
index 31f87ba99abf1bad9f9a0e46816053bea85d7226..1c0df32acc296a050dedb780a3d0c5094cf8a42f 100755 (executable)
@@ -221,8 +221,9 @@ sub get_history {
 sub search {
     my ($self, $params) = @_;
     
-    if ( $params->{offset} and !$params->{limit} ) {
-        ThrowCodeError( 'param_required', { param => 'limit', function => 'Bug.search()'});
+    if ( defined($params->{offset}) and !defined($params->{limit}) ) {
+        ThrowCodeError('param_required', 
+                       { param => 'limit', function => 'Bug.search()' });
     }
     
     $params = _map_fields($params);