-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
aaron@svn.wikimedia.org wrote:
- print( "Flagging bot account edits...\n" );
- # Fill in the rc_bot field
- $sql = "SELECT DISTINCT rc_user FROM $recentchanges " .
"LEFT JOIN $usergroups ON rc_user=ug_user " .
"WHERE ug_group='bot'";
This is fragile, as there's no guarantee that the "bot" group is the only one that has bot privileges, or indeed that it exists at all.
Instead, you should look up which group(s), if any, have the 'bot' permission in $wgGroupPermissions, then search for those groups.
- -- brion vibber (brion @ wikimedia.org)