Followup r104353, updating Special:ProtectedTitles
[lhc/web/wiklou.git] / includes / WikiPage.php
index 1de6c17..599cca4 100644 (file)
@@ -1651,7 +1651,7 @@ class WikiPage extends Page {
        public function doDeleteArticle(
                $reason, $suppress = false, $id = 0, $commit = true, &$error = '', User $user = null
        ) {
-               global $wgUseTrackbacks, $wgUser;
+               global $wgUser;
                $user = is_null( $user ) ? $wgUser : $user;
 
                wfDebug( __METHOD__ . "\n" );
@@ -1744,10 +1744,6 @@ class WikiPage extends Page {
                if ( !$dbw->cascadingDeletes() ) {
                        $dbw->delete( 'revision', array( 'rev_page' => $id ), __METHOD__ );
 
-                       if ( $wgUseTrackbacks ) {
-                               $dbw->delete( 'trackbacks', array( 'tb_page' => $id ), __METHOD__ );
-                       }
-
                        # Delete outgoing links
                        $dbw->delete( 'pagelinks', array( 'pl_from' => $id ), __METHOD__ );
                        $dbw->delete( 'imagelinks', array( 'il_from' => $id ), __METHOD__ );
@@ -2322,7 +2318,9 @@ class WikiPage extends Page {
                # User talk pages
                if ( $title->getNamespace() == NS_USER_TALK ) {
                        $user = User::newFromName( $title->getText(), false );
-                       $user->setNewtalk( false );
+                       if ( $user ) {
+                               $user->setNewtalk( false );
+                       }
                }
 
                # Image redirects
@@ -2792,7 +2790,7 @@ class PoolWorkArticleView extends PoolCounterWork {
         * @return bool
         */
        public function getIsDirty() {
-               return $this->isDirty();
+               return $this->isDirty;
        }
 
        /**
@@ -2849,6 +2847,8 @@ class PoolWorkArticleView extends PoolCounterWork {
                if ( $isCurrent ) {
                        $this->page->doCascadeProtectionUpdates( $this->parserOutput );
                }
+
+               return true;
        }
 
        /**