Changeset 1437 for trunk/system/libraries/drivers/Database_Mysql.php
- Timestamp:
- 12/06/2007 08:15:37 PM (13 months ago)
- Files:
-
- 1 modified
-
trunk/system/libraries/drivers/Database_Mysql.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/system/libraries/drivers/Database_Mysql.php
r1389 r1437 393 393 } 394 394 395 while ($row = $fetch($this->result, $type)) 396 { 397 $rows[] = $row; 398 } 399 400 return $rows; 395 if (mysql_num_rows($this->result)) 396 { 397 // Reset the pointer location to make sure things work properly 398 mysql_data_seek($this->result, 0); 399 400 while ($row = $fetch($this->result, $type)) 401 { 402 $rows[] = $row; 403 } 404 } 405 406 return isset($rows) ? $rows : array(); 401 407 } 402 408 … … 476 482 { 477 483 // Check to see if the requested offset exists. 478 if ( !$this->offsetExists($offset))484 if ( ! $this->offsetExists($offset)) 479 485 return FALSE; 480 486
