Make user functions more generalised so other maintenance scripts can use them

This commit is contained in:
Rob Church 2006-01-16 13:57:29 +00:00
parent afa5ea398e
commit 3236f915eb
2 changed files with 4 additions and 5 deletions

View file

@ -9,9 +9,11 @@
* @author Rob Church <robchur@gmail.com>
*/
define( 'ACTION_REPORT', 0 );
define( 'ACTION_DELETE', 1 );
$options = array( 'delete','help' );
require_once( 'commandLine.inc' );
require_once( 'removeUnusedAccounts.inc' );
require_once( 'userFunctions.inc' );
echo( "Remove Unused Accounts\nThis script will delete all users who have made no edits.\n\n" );

View file

@ -1,16 +1,13 @@
<?php
/**
* Support functions for the removeUnusedAccounts script
* Support functions for dealing with user accounts at a database level
*
* @package MediaWiki
* @subpackage Maintenance
* @author Rob Church <robchur@gmail.com>
*/
define( 'ACTION_REPORT', 0 );
define( 'ACTION_DELETE', 1 );
# Count the number of edits the specified user has made
function CountEdits( $user_id ) {
# We've *got* to pull this stuff off the master. If the user *has* made an edit, but it hasn't