Sort languages by code in Language::fetchLanguageNamesUncached

This is being used in API output in ApiQuerySiteinfo so having
it sorted is nicer.

Bug: T85406
Change-Id: I796112187d17337a1cc12d6752839263b53f40e1
This commit is contained in:
Marius Hoch 2014-12-28 12:51:12 +01:00
parent 61e23c0578
commit dc5db351a6

View file

@ -911,6 +911,7 @@ class Language {
}
if ( $include === 'all' ) {
ksort( $names );
return $names;
}
@ -932,9 +933,11 @@ class Language {
}
}
ksort( $namesMwFile );
return $namesMwFile;
}
ksort( $returnMw );
# 'mw' option; default if it's not one of the other two options (all/mwfile)
return $returnMw;
}