r39315 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r39314‎ | r39315 | r39316 >
Date:23:12, 13 August 2008
Author:aaron
Status:old
Tags:
Comment:
Enabled toned-down email logging
Modified paths:
  • /trunk/extensions/CheckUser/CheckUser.i18n.php (modified) (history)
  • /trunk/extensions/CheckUser/CheckUser.php (modified) (history)

Diff [purge]

Index: trunk/extensions/CheckUser/CheckUser.i18n.php
@@ -66,7 +66,6 @@
6767 'checkuser-log-ipusers-xff' => '$1 got users for XFF $2',
6868
6969 'checkuser-email-action' => 'sent an email to "$1"',
70 - 'checkuser-email-action2' => 'sent an email to "$1" (sender at "$2")',
7170
7271 'checkuser-toollinks' => '<span class="plainlinks">[[http://openrbl.org/query?$1 RDNS] ·
7372 [http://www.robtex.com/rbls/$1.html RBLs] ·
Index: trunk/extensions/CheckUser/CheckUser.php
@@ -35,7 +35,7 @@
3636 # Recent changes data hook
3737 global $wgHooks;
3838 $wgHooks['RecentChange_save'][] = 'efUpdateCheckUserData';
39 -//$wgHooks['EmailUser'][] = 'efUpdateCheckUserEmailData'; // do not use at present
 39+$wgHooks['EmailUser'][] = 'efUpdateCheckUserEmailData';
4040
4141 $wgHooks['ParserTestTables'][] = 'efCheckUserParserTestTables';
4242 $wgHooks['LoadExtensionSchemaUpdates'][] = 'efCheckUserSchemaUpdates';
@@ -115,7 +115,6 @@
116116 * Saves user data into the cu_changes table
117117 */
118118 function efUpdateCheckUserEmailData( $to, $from, $subject, $text ) {
119 - die("Do not use at present.");
120119 wfLoadExtensionMessages( 'CheckUser' );
121120 $user = User::newFromName( $to->name );
122121 $userPage = $user->getUserPage();
@@ -138,10 +137,8 @@
139138 'cuc_minor' => 0,
140139 'cuc_user' => $user->getId(),
141140 'cuc_user_text' => $user->getName(),
142 - 'cuc_actiontext' => $from->address ?
143 - wfMsgForContent('checkuser-email-action2',$to->name,$from->address) :
144 - wfMsgForContent('checkuser-email-action',$to->name),
145 - 'cuc_comment' => $subject,
 141+ 'cuc_actiontext' => wfMsgForContent('checkuser-email-action',$to->name),
 142+ 'cuc_comment' => '',
146143 'cuc_this_oldid' => 0,
147144 'cuc_last_oldid' => 0,
148145 'cuc_type' => RC_LOG,

Status & tagging log