X-Git-Url: https://git.mdrn.pl/redakcja.git/blobdiff_plain/df341bdd09208d2b0f84060454cc0000df19deba..54612c196135c939a7d17d51b81b1357f6eac9c3:/src/redakcja/static/js/wiki/loader_readonly.js?ds=sidebyside diff --git a/src/redakcja/static/js/wiki/loader_readonly.js b/src/redakcja/static/js/wiki/loader_readonly.js index 43b8c9b8..2d311239 100644 --- a/src/redakcja/static/js/wiki/loader_readonly.js +++ b/src/redakcja/static/js/wiki/loader_readonly.js @@ -72,22 +72,8 @@ $(function() /* Load configuration */ $.wiki.loadConfig(); - var initAll = function(a, f) { - if (a.length == 0) return f(); - - $.wiki.initTab({ - tab: a.pop(), - doc: CurrentDocument, - callback: function(){ - initAll(a, f); - } - }); - }; - - - /* - * Initialize all perspectives - */ - initAll( $.makeArray($('#tabs li')), initialize); - console.log(location.hash); + $('.tabs li').each((i, e) => { + $.wiki.initTab({tab: e, doc: CurrentDocument}); + }); + initialize(); });