r34859 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r34858‎ | r34859 | r34860 >
Date:14:14, 15 May 2008
Author:ialex
Status:old
Tags:
Comment:
Some more cleanup:
* Remove double declared of LogLine hook
* Force messages loading, breaks IRC notifications
Modified paths:
  • /trunk/extensions/Newuserlog/Newuserlog.php (modified) (history)

Diff [purge]

Index: trunk/extensions/Newuserlog/Newuserlog.php
@@ -37,9 +37,6 @@
3838 # Run this hook on Special:Log
3939 $wgHooks['LogLine'][] = 'wfNewuserlogLogLine';
4040
41 -# Run this hook on Special:Log
42 -$wgHooks['LogLine'][] = 'wfNewuserlogLogLine';
43 -
4441 function wfNewuserlogHook( $user = null, $byEmail = false ) {
4542 global $wgUser, $wgContLang, $wgVersion;
4643
@@ -47,6 +44,7 @@
4845 // Compatibility with old versions which didn't pass the parameter
4946 $user = $wgUser;
5047 }
 48+ wfLoadExtensionMessages( 'Newuserlog' );
5149
5250 $talk = $wgContLang->getFormattedNsText( NS_TALK );
5351
@@ -57,7 +55,6 @@
5856 // Links not necessary for self-creations, they will appear already in
5957 // recentchanges and special:log view for the creating user.
6058
61 - wfLoadExtensionMessages( 'Newuserlog' );
6259 $contribs = wfMsgForContent( 'contribslink' );
6360 $block = wfMsgForContent( 'blocklink' );
6461 $action = 'create2';
@@ -71,6 +68,7 @@
7269 }
7370
7471 function wfNewuserlogAutoCreate( $user ) {
 72+ wfLoadExtensionMessages( 'Newuserlog' );
7573 $log = new LogPage( 'newusers' );
7674 $log->addEntry( 'autocreate', $user->getUserPage(), '', array( $user->getId() ) );
7775 return true;

Status & tagging log