Daniel Kinzler has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/159504

Change subject: Do deletion updates after commit.
......................................................................

Do deletion updates after commit.

WikiPage::doDeleteArticleReal now triggers secondary data updates
(link tables, etc) only after the deletion proper is committed.
This is consistent with the way doEditContent applies secondary
data updates, and avoids nested transactions (e.g. by one of the
updates using a retry loop).

Change-Id: Ie4d96f77d210c9953104a0e6fb11ea8ed348c42a
---
M includes/page/WikiPage.php
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/04/159504/1

diff --git a/includes/page/WikiPage.php b/includes/page/WikiPage.php
index b62f40d..9ade16e 100644
--- a/includes/page/WikiPage.php
+++ b/includes/page/WikiPage.php
@@ -2876,8 +2876,6 @@
                // Clone the title, so we have the information we need when we 
log
                $logTitle = clone $this->mTitle;
 
-               $this->doDeleteUpdates( $id, $content );
-
                // Log the deletion, if the page was suppressed, log it at 
Oversight instead
                $logtype = $suppress ? 'suppress' : 'delete';
 
@@ -2896,6 +2894,8 @@
                        $dbw->commit( __METHOD__ );
                }
 
+               $this->doDeleteUpdates( $id, $content );
+
                wfRunHooks( 'ArticleDeleteComplete', array( &$this, &$user, 
$reason, $id, $content, $logEntry ) );
                $status->value = $logid;
                return $status;

-- 
To view, visit https://gerrit.wikimedia.org/r/159504
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie4d96f77d210c9953104a0e6fb11ea8ed348c42a
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Daniel Kinzler <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to