Skip to content

Commit fece884

Browse files
committed
Fixed return line and comments
1 parent d981e29 commit fece884

File tree

1 file changed

+3
-8
lines changed

1 file changed

+3
-8
lines changed

system/database/DB_result.php

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -373,17 +373,12 @@ public function previous_row($type = 'object')
373373
/**
374374
* Returns an unbuffered row and move pointer to next row
375375
*
376-
* @return object
376+
* @return mixed either a result object or array
377377
*/
378378
public function unbuffered_row($type = 'object')
379379
{
380-
if ($type == 'object')
381-
{
382-
return $this->_fetch_object();
383-
} else
384-
{
385-
return $this->_fetch_assoc();
386-
}
380+
return ($type !== 'array') ? $this->_fetch_object() : $this->_fetch_assoc();
381+
387382
}
388383

389384
// --------------------------------------------------------------------

0 commit comments

Comments
 (0)