From f5f9c3bb313c69f2b00bee562a2200dbb82ecd9d Mon Sep 17 00:00:00 2001 From: FrozenCow Date: Wed, 10 Aug 2011 23:32:33 +0200 Subject: [PATCH] Use shift, not pop, for queue. --- web/js/dynmaputils.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/js/dynmaputils.js b/web/js/dynmaputils.js index d4656ef0..25142090 100644 --- a/web/js/dynmaputils.js +++ b/web/js/dynmaputils.js @@ -121,7 +121,7 @@ var DynmapTileLayer = L.TileLayer.extend({ }, _nextLoadTile: function() { if (this._loadingTiles.length > 4) { return; } - var next = this._loadQueue.pop(); + var next = this._loadQueue.shift(); if (!next) { return; } next.loadSrc();