Skip to content

Commit

Permalink
Load plugins asynchronously
Browse files Browse the repository at this point in the history
  • Loading branch information
pauloborges committed Feb 9, 2015
1 parent 2764674 commit 0713fc9
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions mapbox.js
Original file line number Diff line number Diff line change
Expand Up @@ -144,13 +144,11 @@ var onMapboxLoaded = function (plugins, cb) {
cb();
return;
}

plugin = plugins.shift();
loadFiles(FILES[plugin], loadCb);
};

var plugin = plugins.shift();
loadFiles(FILES[plugin], loadCb);
_.each(plugins, function (plugin) {
loadFiles(FILES[plugin], loadCb);
});
};

var loadScript = function (src, cb) {
Expand Down

0 comments on commit 0713fc9

Please sign in to comment.