Merge "mw.Platform: Only add split lang codes with a dash"

This commit is contained in:
jenkins-bot 2013-10-31 17:24:34 +00:00 committed by Gerrit Code Review
commit 519a35dfe4
2 changed files with 2 additions and 2 deletions

View file

@ -85,7 +85,7 @@ ve.init.mw.Platform.prototype.getUserLanguages = function () {
langParts = lang.split( '-' ),
langs = [ lang ];
if ( langParts.length > 0 ) {
if ( langParts.length > 1 ) {
langs.push( langParts[0] );
}

View file

@ -115,7 +115,7 @@ ve.init.sa.Platform.prototype.getUserLanguages = function () {
langParts = lang.split( '-' ),
langs = [ lang ];
if ( langParts.length > 0 ) {
if ( langParts.length > 1 ) {
langs.push( langParts[0] );
}