Merge "Clone the Title object to prevent mutations."
[lhc/web/wiklou.git] / includes / FileDeleteForm.php
index eb0052c..3e0595e 100644 (file)
@@ -120,9 +120,10 @@ class FileDeleteForm {
 
                        if ( !$status->isGood() ) {
                                $wgOut->addHTML( '<h2>' . $this->prepareMessage( 'filedeleteerror-short' ) . "</h2>\n" );
-                               $wgOut->addWikiText( '<div class="error">' .
+                               $wgOut->wrapWikiTextAsInterface(
+                                       'error',
                                        $status->getWikiText( 'filedeleteerror-short', 'filedeleteerror-long' )
-                                       . '</div>' );
+                               );
                        }
                        if ( $status->isOK() ) {
                                $wgOut->setPageTitle( wfMessage( 'actioncomplete' ) );
@@ -148,7 +149,7 @@ class FileDeleteForm {
         * @param string &$oldimage Archive name
         * @param string $reason Reason of the deletion
         * @param bool $suppress Whether to mark all deleted versions as restricted
-        * @param User $user User object performing the request
+        * @param User|null $user User object performing the request
         * @param array $tags Tags to apply to the deletion action
         * @throws MWException
         * @return Status