function doDelete( $delete = false, $args = array() ) {
# Data should come off the master, wrapped in a transaction
- $dbw = wfGetDB( DB_MASTER );
- $dbw->begin( __METHOD__ );
+ $dbw = $this->getDB( DB_MASTER );
+ $this->beginTransaction( $dbw, __METHOD__ );
$pageConds = array();
$revConds = array();
# This bit's done
# Purge redundant text records
- $dbw->commit( __METHOD__ );
+ $this->commitTransaction( $dbw, __METHOD__ );
if ( $delete ) {
$this->purgeRedundantText( true );
}