From: Greg Sabino Mullane Date: Thu, 27 Mar 2008 21:55:39 +0000 (+0000) Subject: Wrap timestamp for DB query in $dbr->timestamp() call. Bug 13532. X-Git-Tag: 1.31.0-rc.0~48764 X-Git-Url: http://git.cyclocoop.org/%24image?a=commitdiff_plain;h=6eca1220568a4f78da9d6ef7b59f54b6ef78aab6;p=lhc%2Fweb%2Fwiklou.git Wrap timestamp for DB query in $dbr->timestamp() call. Bug 13532. --- diff --git a/includes/filerepo/OldLocalFile.php b/includes/filerepo/OldLocalFile.php index bc712c75c6..ea6b1d0f12 100644 --- a/includes/filerepo/OldLocalFile.php +++ b/includes/filerepo/OldLocalFile.php @@ -168,7 +168,7 @@ class OldLocalFile extends LocalFile { if ( is_null( $this->requestedTime ) ) { $conds['oi_archive_name'] = $this->archive_name; } else { - $conds[] = 'oi_timestamp <= ' . $dbr->addQuotes( $this->requestedTime ); + $conds[] = 'oi_timestamp <= ' . $dbr->addQuotes( $dbr->timestamp( $this->requestedTime ) ); } $row = $dbr->selectRow( 'oldimage', $this->getCacheFields( 'oi_' ), $conds, __METHOD__, array( 'ORDER BY' => 'oi_timestamp DESC' ) );