diff options
Diffstat (limited to 'includes/specials/SpecialUndelete.php')
-rw-r--r-- | includes/specials/SpecialUndelete.php | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/includes/specials/SpecialUndelete.php b/includes/specials/SpecialUndelete.php index f2362a18..a66a3d10 100644 --- a/includes/specials/SpecialUndelete.php +++ b/includes/specials/SpecialUndelete.php @@ -149,7 +149,8 @@ class PageArchive { $fields, $conds, $join_conds, - $options + $options, + '' ); return $dbr->select( $tables, @@ -756,8 +757,8 @@ class SpecialUndelete extends SpecialPage { * @param User $user * @return bool */ - private function isAllowed( $permission, User $user = null ) { - $user = $user ? : $this->getUser(); + protected function isAllowed( $permission, User $user = null ) { + $user = $user ?: $this->getUser(); if ( $this->mTargetObj !== null ) { return $this->mTargetObj->userCan( $permission, $user ); } else { @@ -770,6 +771,8 @@ class SpecialUndelete extends SpecialPage { } function execute( $par ) { + $this->useTransactionalTimeLimit(); + $user = $this->getUser(); $this->setHeaders(); @@ -998,7 +1001,7 @@ class SpecialUndelete extends SpecialPage { return; } - if ( $this->mPreview || !$isText ) { + if ( ( $this->mPreview || !$isText ) && $content ) { // NOTE: non-text content has no source view, so always use rendered preview // Hide [edit]s @@ -1206,7 +1209,7 @@ class SpecialUndelete extends SpecialPage { $repo->streamFile( $path ); } - private function showHistory() { + protected function showHistory() { $out = $this->getOutput(); if ( $this->mAllowed ) { $out->addModules( 'mediawiki.special.undelete' ); @@ -1377,7 +1380,7 @@ class SpecialUndelete extends SpecialPage { return true; } - private function formatRevisionRow( $row, $earliestLiveTime, $remaining ) { + protected function formatRevisionRow( $row, $earliestLiveTime, $remaining ) { $rev = Revision::newFromArchiveRow( $row, array( 'title' => $this->mTargetObj |