Index: trunk/extensions/CustomUserSignup/CustomUserSignup.hooks.php |
— | — | @@ -114,6 +114,12 @@ |
115 | 115 | $out->addModules( 'ext.UserBuckets' ); |
116 | 116 | return true; |
117 | 117 | } |
| 118 | + |
| 119 | + public static function makeGlobalVariablesScript( &$vars ) { |
| 120 | + global $wgCustomUserSignupTrackAccountCreations; |
| 121 | + $vars['wgCustomUserSignupTrackAccountCreations'] = $wgCustomUserSignupTrackAccountCreations; |
| 122 | + return true; |
| 123 | + } |
118 | 124 | |
119 | 125 | public static function addNewAccount( $user, $byEmail ){ |
120 | 126 | global $wgRequest, $wgTitle, $wgCustomUserSignupTrackAccountCreations; |
Index: trunk/extensions/CustomUserSignup/modules/AccountCreationUserBucket.js |
— | — | @@ -60,6 +60,7 @@ |
61 | 61 | // "allActive" is reserved. |
62 | 62 | // If this function exists, it will be apply to every user not in the "none" bucket |
63 | 63 | "allActive": function(){ |
| 64 | + if ( !mw.config.get( 'wgCustomUserSignupTrackAccountCreations' ) ) { return; } |
64 | 65 | |
65 | 66 | //track account creation attempts |
66 | 67 | $j("#wpCreateaccount").click(function(){ $j.trackAction('submit-signup-data'); }); |