Unverified Commit bef35e90 authored by Marco Pivetta's avatar Marco Pivetta Committed by GitHub

Merge pull request #3331 from michaelcullum/fetch-all

Fetch all should use the driver statement's fetchAll method
parents 1b1adc2a e35d5e12
......@@ -166,12 +166,7 @@ class ResultCacheStatement implements IteratorAggregate, ResultStatement
*/
public function fetchAll($fetchMode = null, $fetchArgument = null, $ctorArgs = null)
{
$rows = [];
while ($row = $this->fetch($fetchMode)) {
$rows[] = $row;
}
return $rows;
return $this->statement->fetchAll($fetchMode, $fetchArgument, $ctorArgs);
}
/**
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment