diff options
Diffstat (limited to 'maintenance/purgeOldText.inc')
-rw-r--r-- | maintenance/purgeOldText.inc | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/maintenance/purgeOldText.inc b/maintenance/purgeOldText.inc index 0bf6225a..c4732e97 100644 --- a/maintenance/purgeOldText.inc +++ b/maintenance/purgeOldText.inc @@ -3,15 +3,14 @@ /** * Support functions for cleaning up redundant text records * - * @package MediaWiki - * @subpackage Maintenance + * @addtogroup Maintenance * @author Rob Church <robchur@gmail.com> */ function PurgeRedundantText( $delete = false ) { # Data should come off the master, wrapped in a transaction - $dbw =& wfGetDB( DB_MASTER ); + $dbw = wfGetDB( DB_MASTER ); $dbw->begin(); $tbl_arc = $dbw->tableName( 'archive' ); @@ -38,6 +37,7 @@ function PurgeRedundantText( $delete = false ) { echo( "Searching for inactive text records..." ); $set = implode( ', ', $cur ); $res = $dbw->query( "SELECT old_id FROM $tbl_txt WHERE old_id NOT IN ( $set )" ); + $old = array(); while( $row = $dbw->fetchObject( $res ) ) { $old[] = $row->old_id; } @@ -60,4 +60,4 @@ function PurgeRedundantText( $delete = false ) { } -?>
\ No newline at end of file +?> |