Remove JavaScript side injection of message 'categorytree-expand'

The JavaScript side injection of message 'categorytree-expand' was introduced in 026cc407.
The intent of not initializing $wgLang does not work anymore, because
there are some other wfMessage() calls in the same request.

Change-Id: Idf0815654e1e095acccbe10afe0726bc8766f8ae
This commit is contained in:
Fomafix 2016-01-31 23:45:00 +00:00 committed by [[mw:User:Fomafix]]
parent f37ad97bb1
commit 4b4a630807
2 changed files with 1 additions and 3 deletions

View file

@ -637,8 +637,7 @@ class CategoryTree {
$tag = 'span';
if ( $children == 0 ) {
$txt = wfMessage( 'categorytree-expand-bullet' )->plain();
# Don't load this message for ajax requests, so that we don't have to initialise $wgLang
$linkattr[ 'title' ] = $this->mIsAjaxRequest ? '##LOAD##' : wfMessage( 'categorytree-expand' )->plain();
$linkattr[ 'title' ] = wfMessage( 'categorytree-expand' )->plain();
$linkattr[ 'data-ct-state' ] = 'collapsed';
} else {
$txt = wfMessage( 'categorytree-collapse-bullet' )->plain();

View file

@ -133,7 +133,6 @@
formatversion: 2
} ).done( function ( data ) {
data = data.categorytree.html;
data = data.replace( /##LOAD##/g, mw.msg( 'categorytree-expand' ) );
if ( data === '' ) {
switch ( ctMode ) {