Skip to content

Commit

Permalink
Fix up buffer benchmarks
Browse files Browse the repository at this point in the history
  • Loading branch information
Anand Thakker committed Sep 2, 2016
1 parent dfcf309 commit a8fffd9
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions bench/lib/run_tile_series.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,20 +78,20 @@ function preloadAssets(stylesheet, perTileCallback, callback) {
var style = new Style(stylesheet);

var worker = new Worker({addEventListener: function() {} });
worker['set layers'](stylesheet.layers);
var layerFamilies = worker.layerFamilies;
worker['set layers'](0, stylesheet.layers);
var layerFamilies = worker.layerFamilies[0];

style.once('load', function() {
var assets = {
getGlyphs: function (params, callback) {
style['get glyphs'](params, function(err, glyphs) {
style['get glyphs'](null, params, function(err, glyphs) {
cache.glyphs[JSON.stringify(params)] = glyphs;
callback(err, glyphs);
});
},

getIcons: function (params, callback) {
style['get icons'](params, function(err, icons) {
style['get icons'](null, params, function(err, icons) {
cache.icons[JSON.stringify(params)] = icons;
callback(err, icons);
});
Expand Down

0 comments on commit a8fffd9

Please sign in to comment.