]> git.mjollnir.org Git - moodle.git/commitdiff
Fixed bug in get_records_sql(). This call:
authorvyshane <vyshane>
Fri, 15 Sep 2006 06:03:32 +0000 (06:03 +0000)
committervyshane <vyshane>
Fri, 15 Sep 2006 06:03:32 +0000 (06:03 +0000)
$rs = get_recordset_sql($sql, $limitfrom='', $limitnum='');

should really be:

$rs = get_recordset_sql($sql, $limitfrom, $limitnum);

lib/dmllib.php

index 1edb34e236c9698d0441e7f74f93efef615e90a6..e1589468a537620540ccd770bf75dab8dca67635 100644 (file)
@@ -590,7 +590,6 @@ function get_recordset_list($table, $field='', $values='', $sort='', $fields='*'
  * @return mixed an ADODB RecordSet object, or false if an error occured.
  */
 function get_recordset_sql($sql, $limitfrom=null, $limitnum=null) {
-
     global $CFG, $db;
 
     if (empty($db)) {
@@ -736,7 +735,7 @@ function get_records_list($table, $field='', $values='', $sort='', $fields='*',
  * @return mixed an array of objects, or false if no records were found or an error occured.
  */
 function get_records_sql($sql, $limitfrom='', $limitnum='') {
-    $rs = get_recordset_sql($sql, $limitfrom='', $limitnum='');
+    $rs = get_recordset_sql($sql, $limitfrom, $limitnum);
     return recordset_to_array($rs);
 }