summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'MLEB/UniversalLanguageSelector/resources/js/ext.uls.preferences.js')
-rw-r--r--MLEB/UniversalLanguageSelector/resources/js/ext.uls.preferences.js8
1 files changed, 4 insertions, 4 deletions
diff --git a/MLEB/UniversalLanguageSelector/resources/js/ext.uls.preferences.js b/MLEB/UniversalLanguageSelector/resources/js/ext.uls.preferences.js
index 0569fab4..0afc40b2 100644
--- a/MLEB/UniversalLanguageSelector/resources/js/ext.uls.preferences.js
+++ b/MLEB/UniversalLanguageSelector/resources/js/ext.uls.preferences.js
@@ -102,7 +102,7 @@
* Set the preference
*
* @param {string} key
- * @param {mixed} value
+ * @param {Mixed} value
*/
set: function ( key, value ) {
this.preferences[ key ] = value;
@@ -126,7 +126,7 @@
save: function ( callback ) {
var ulsPreferences = this;
- callback = callback || $.noop;
+ callback = callback || function () {};
if ( this.isAnon ) {
// Anonymous user. Save preferences in local storage
preferenceStore().set( this.preferenceName, this.preferences );
@@ -147,10 +147,10 @@
mw.uls = mw.uls || {};
mw.uls.preferences = function () {
- var data = $( 'body' ).data( 'preferences' );
+ var data = $( document.body ).data( 'preferences' );
if ( !data ) {
- $( 'body' ).data( 'preferences', ( data = new ULSPreferences() ) );
+ $( document.body ).data( 'preferences', ( data = new ULSPreferences() ) );
}
return data;
};