From 5f7532403017c84937f25e2e3426622fb072bcb0 Mon Sep 17 00:00:00 2001 From: streetlogics Date: Tue, 10 Dec 2013 15:13:23 -0700 Subject: [PATCH] Fix for issue 72? Call me crazy, but if this is return false, this function will always return false, since emptyBucket defaults to true, and therefore the call to set emptyBucket to false will never execute? --- methods/realtime-candle-fetcher.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/methods/realtime-candle-fetcher.js b/methods/realtime-candle-fetcher.js index ef321d74c..f71e27518 100644 --- a/methods/realtime-candle-fetcher.js +++ b/methods/realtime-candle-fetcher.js @@ -64,7 +64,7 @@ CandleCalculator.prototype.fillBuckets = function(trades) { // it should go to the next bucket while(time > nextBucketTime) { if(emptyBucket === true) - return false; + break; // we can calculate the candle of the freshly filled bucket this.calculateCandle();