Index: apachesolr.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/apachesolr/apachesolr.module,v
retrieving revision 1.1.2.12.2.210
diff -u -r1.1.2.12.2.210 apachesolr.module
--- apachesolr.module	11 Aug 2010 21:49:19 -0000	1.1.2.12.2.210
+++ apachesolr.module	24 Aug 2010 23:32:23 -0000
@@ -20,7 +20,7 @@
     set_include_path(dirname(__FILE__) . PATH_SEPARATOR . get_include_path());
     require_once 'Zend/Json/Decoder.php';
     require_once 'Zend/Json/Encoder.php';
-  
+
     /**
      * Substitute for missing PHP built-in functions.
      */
@@ -332,7 +332,7 @@
       case 'mysqli':
         db_query("DELETE FROM {apachesolr_search_node} USING {apachesolr_search_node} asn INNER JOIN {node} n ON asn.nid = n.nid WHERE n.type = '%s'", $type);
         break;
-      default: 
+      default:
         db_query("DELETE FROM {apachesolr_search_node} WHERE nid IN (SELECT nid FROM {node} WHERE type = '%s')", $type);
         break;
     }
@@ -1331,7 +1331,11 @@
  *
  * @throws Exception
  */
-function apachesolr_do_query($caller, $current_query, $params = array('rows' => 10), $page = 0) {
+function apachesolr_do_query($caller, $current_query, &$params, $page = 0) {
+  if (empty($params)) {
+    array('rows' => 10);
+  }
+
   // Allow modules to alter the query prior to statically caching it.
   // This can e.g. be used to add available sorts.
   foreach (module_implements('apachesolr_prepare_query') as $module) {
@@ -1985,7 +1989,7 @@
   function remove_subqueries();
 }
 
-/** 
+/**
  * Wrapper function for tt() if i18nstrings enabled.
  */
 function apachesolr_tt($name, $string, $langcode = NULL, $update = FALSE) {
