Merge "Convert Special:DeletedContributions to use OOUI."
[lhc/web/wiklou.git] / includes / filerepo / file / ArchivedFile.php
index ca1ea84..921e129 100644 (file)
@@ -177,7 +177,7 @@ class ArchivedFile {
 
                if ( !$this->title || $this->title->getNamespace() == NS_FILE ) {
                        $this->dataLoaded = true; // set it here, to have also true on miss
-                       $dbr = wfGetDB( DB_SLAVE );
+                       $dbr = wfGetDB( DB_REPLICA );
                        $row = $dbr->selectRow(
                                'filearchive',
                                self::selectFields(),
@@ -425,6 +425,7 @@ class ArchivedFile {
         */
        function pageCount() {
                if ( !isset( $this->pageCount ) ) {
+                       // @FIXME: callers expect File objects
                        if ( $this->getHandler() && $this->handler->isMultiPage( $this ) ) {
                                $this->pageCount = $this->handler->pageCount( $this );
                        } else {