function showSearchForm() {
$out = $this->getOutput();
$out->setPageTitle( $this->msg( 'undelete-search-title' ) );
- $fuzzySearch = $this->getRequest()->getVal( 'fuzzy', false );
+ $fuzzySearch = $this->getRequest()->getVal( 'fuzzy', true );
$out->enableOOUI();
$fieldset,
new OOUI\HtmlSnippet(
Html::hidden( 'title', $this->getPageTitle()->getPrefixedDBkey() ) .
- Html::hidden( 'fuzzy', $this->getRequest()->getVal( 'fuzzy' ) )
+ Html::hidden( 'fuzzy', $fuzzySearch )
)
);
$archive = new PageArchive( $this->mTargetObj, $this->getConfig() );
Hooks::run( 'UndeleteForm::showHistory', [ &$archive, $this->mTargetObj ] );
- /*
- $text = $archive->getLastRevisionText();
- if( is_null( $text ) ) {
- $out->addWikiMsg( 'nohistory' );
- return;
- }
- */
+
$out->addHTML( '<div class="mw-undelete-history">' );
if ( $this->mAllowed ) {
$out->addWikiMsg( 'undeletehistory' );
$misc = Html::hidden( 'target', $this->mTarget );
$misc .= Html::hidden( 'wpEditToken', $this->getUser()->getEditToken() );
$history .= $misc;
- }
-
- $form->appendContent( new OOUI\HtmlSnippet( $history ) );
- $out->addHTML( $form );
+ $form->appendContent( new OOUI\HtmlSnippet( $history ) );
+ $out->addHTML( $form );
+ } else {
+ $out->addHTML( $history );
+ }
return true;
}