Fire language change hook

As of Id345e933, we fire the language change hook when the user switches
language by clicking on a link in the languages list. In order to
compare the user switching language in the scenario above with the user
switching language via the CLS and/or Vector's language switcher, ensure
that we fire language change hook in all treatments.

Bug: T280770
Change-Id: I4a74254612557c287b16f4f086077a2637de9a2e
This commit is contained in:
Sam Smith
2021-06-10 10:28:58 +01:00
committed by jenkins-bot
parent 2c46226f83
commit bc14f8fa40

View File

@@ -60,6 +60,9 @@ function launchULS( $trigger, languagesObject, forCLS ) {
) {
return;
}
mw.hook( 'mw.uls.interface.language.change' ).fire( language );
location.href = languagesObject[ language ].href;
},
onPosition: function () {