Index: trunk/extensions/EducationProgram/includes/EPUtils.php |
— | — | @@ -45,7 +45,7 @@ |
46 | 46 | else { |
47 | 47 | // Compatibility with MediaWiki 1.18. |
48 | 48 | $log = new LogPage( $info['type'] ); |
49 | | - |
| 49 | + |
50 | 50 | $log->addEntry( |
51 | 51 | $info['subtype'], |
52 | 52 | $info['title'], |
Index: trunk/extensions/EducationProgram/resources/ep.instructor.js |
— | — | @@ -125,9 +125,9 @@ |
126 | 126 | $add.button( 'option', 'label', ep.msg( 'ep-instructor-adding' ) ); |
127 | 127 | |
128 | 128 | ep.api.addInstructor( { |
129 | | - 'courseid': this.courseId, |
130 | | - 'username': this.getName(), |
131 | | - 'reason': this.summaryInput.val() |
| 129 | + 'courseid': _this.courseId, |
| 130 | + 'username': _this.getName(), |
| 131 | + 'reason': _this.summaryInput.val() |
132 | 132 | } ).done( function() { |
133 | 133 | _this.$dialog.text( ep.msg( |
134 | 134 | _this.selfMode ? 'ep-instructor-addittion-self-success' : 'ep-instructor-addittion-success', |
Index: trunk/extensions/EducationProgram/EducationProgram.hooks.php |
— | — | @@ -152,12 +152,22 @@ |
153 | 153 | */ |
154 | 154 | public static function formatLogEntry( $type, $action, Title $title, $forUI, array $params ) { |
155 | 155 | global $wgContLang, $wgLang; |
156 | | - |
157 | | - return wfMessage( 'logentry-' . $type . '-' . $action )->params( |
158 | | - '', // User link in the new system |
159 | | - '#', // User name for gender in the new system |
160 | | - Message::rawParam( $forUI ? Linker::link( $title ) : $title->getPrefixedText() ) |
161 | | - )->inLanguage( $forUI === null ? $wgContLang : $wgLang )->text(); |
| 156 | + |
| 157 | + $message = wfMessage( 'logentry-' . $type . '-' . $action ); |
| 158 | + |
| 159 | + $message = call_user_func_array( |
| 160 | + array( $message, 'params' ), |
| 161 | + array_merge( |
| 162 | + array( |
| 163 | + '', // User link in the new system |
| 164 | + '#', // User name for gender in the new system |
| 165 | + Message::rawParam( $forUI ? Linker::link( $title ) : $title->getPrefixedText() ) |
| 166 | + ), |
| 167 | + $params |
| 168 | + ) |
| 169 | + ); |
| 170 | + |
| 171 | + return $message->inLanguage( $forUI === null ? $wgContLang : $wgLang )->text(); |
162 | 172 | } |
163 | 173 | |
164 | 174 | } |