Found an error when $res = false while running tests
authorMark A. Hershberger <mah@users.mediawiki.org>
Tue, 7 Dec 2010 22:58:29 +0000 (22:58 +0000)
committerMark A. Hershberger <mah@users.mediawiki.org>
Tue, 7 Dec 2010 22:58:29 +0000 (22:58 +0000)
includes/filerepo/ArchivedFile.php

index ecc0997..b4e1cc5 100644 (file)
@@ -119,8 +119,7 @@ class ArchivedFile {
                                $conds,
                                __METHOD__,
                                array( 'ORDER BY' => 'fa_timestamp DESC' ) );
-
-                       if ( $dbr->numRows( $res ) == 0 ) {
+                       if ( $res == false || $dbr->numRows( $res ) == 0 ) {
                        // this revision does not exist?
                                return;
                        }