Page MenuHomePhabricator

Use LogPage::addRelations in Renameuser logging
Open, LowPublicFeature

Description

While working on logging, Aaron Schultz suggested an addition to Renameuser logging on https://gerrit.wikimedia.org/r/#/c/5288/3/Renameuser_body.php (comments 3 and 4:

  • I recommend using LogPage::addRelations( 'oldname', array( $oldusername ), $logid ). This way, you can also list renames to/from a user using LogEventsList::showLogExtract() by adding le_field, le_log_id conditions to $conds. RevisionDelete uses this to get log entries that effect specific revision IDs.
  • Of course, you'd also need LogPage::addRelations( 'newname', array( $newusername->getText() ), $logid ).

As this was out of scope of a update, leaving this issue.


Version: master
Severity: normal
URL: https://gerrit.wikimedia.org/r/#/c/5288/3

Details

Reference
bz37016

Related Objects

StatusSubtypeAssignedTask
OpenFeatureNone
OpenFeatureNone

Event Timeline

bzimport raised the priority of this task from to Low.Nov 22 2014, 12:26 AM
bzimport set Reference to bz37016.
bzimport added a subscriber: Unknown Object (MLST).
DannyS712 changed the subtype of this task from "Task" to "Feature Request".Apr 1 2020, 1:57 AM
DannyS712 added a project: MediaWiki-Logevents.
DannyS712 edited subscribers, added: DannyS712; removed: wikibugs-l-list.

For reference, the relevant logic for logging renames is in RenameuserSQL::rename under the comment // Log it!
Also, this should probably be setRelations