summaryrefslogtreecommitdiff
path: root/includes
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2011-09-11 13:00:57 -0400
committerDries Buytaert <dries@buytaert.net>2011-09-11 13:00:57 -0400
commitf3365697b70384de8f03e745ef404b66d62c84b0 (patch)
tree8c784bc40d2c1021ac571d771a00cd88290da496 /includes
parentc843ac8df05c953aa7857bc21a5c998ff9bb092a (diff)
downloadbrdo-f3365697b70384de8f03e745ef404b66d62c84b0.tar.gz
brdo-f3365697b70384de8f03e745ef404b66d62c84b0.tar.bz2
- Patch #1266694 by Damien Tournoud: Fixed DatabaseStatementPrefetch doesn't implement fetchColumn().
Diffstat (limited to 'includes')
-rw-r--r--includes/database/prefetch.inc6
1 files changed, 5 insertions, 1 deletions
diff --git a/includes/database/prefetch.inc b/includes/database/prefetch.inc
index f378d3555..4f2b19d1f 100644
--- a/includes/database/prefetch.inc
+++ b/includes/database/prefetch.inc
@@ -370,7 +370,7 @@ class DatabaseStatementPrefetch implements Iterator, DatabaseStatementInterface
}
}
- public function fetchField($index = 0) {
+ public function fetchColumn($index = 0) {
if (isset($this->currentRow) && isset($this->columnNames[$index])) {
// We grab the value directly from $this->data, and format it.
$return = $this->currentRow[$this->columnNames[$index]];
@@ -382,6 +382,10 @@ class DatabaseStatementPrefetch implements Iterator, DatabaseStatementInterface
}
}
+ public function fetchField($index = 0) {
+ return $this->fetchColumn($index);
+ }
+
public function fetchObject($class_name = NULL, $constructor_args = array()) {
if (isset($this->currentRow)) {
if (!isset($class_name)) {