X-Git-Url: http://git.heureux-cyclage.org/?a=blobdiff_plain;f=resources%2Fsrc%2Fmediawiki.toolbar%2Ftoolbar.js;h=827ef0194b10eac1a76465cef0204817df09cebc;hb=cb68d6dacf0523fb3ce7c4f8b450c54b99733cfa;hp=9ee499c096c4855958c8797e2e51fe5e5ce3465a;hpb=2faa92719e57acf476080693bddc824d7ee98449;p=lhc%2Fweb%2Fwiklou.git diff --git a/resources/src/mediawiki.toolbar/toolbar.js b/resources/src/mediawiki.toolbar/toolbar.js index 9ee499c096..827ef0194b 100644 --- a/resources/src/mediawiki.toolbar/toolbar.js +++ b/resources/src/mediawiki.toolbar/toolbar.js @@ -84,7 +84,7 @@ /** * @private * @property {Array} - * Contains button objects (and for backwards compatibilty, it can + * Contains button objects (and for backwards compatibility, it can * also contains an arguments array for insertButton). */ queue = []; @@ -128,8 +128,8 @@ buttons = slice.call( arguments ); } if ( isReady ) { - $.each( buttons, function () { - insertButton( this ); + buttons.forEach( function ( button ) { + insertButton( button ); } ); } else { // Push each button into the queue @@ -168,7 +168,7 @@ // Expose API publicly // @deprecated since MW 1.29 - mw.log.deprecate( mw, 'toolbar', toolbar ); + mw.log.deprecate( mw, 'toolbar', toolbar, null, 'mw.toolbar' ); $( function () { var i, button;