From cc4bba6f5291ac9c280fe3841027de14e822607d Mon Sep 17 00:00:00 2001 From: Mario Colque Date: Thu, 23 Jan 2014 18:15:58 -0300 Subject: [PATCH] live transactions limited --- public/js/controllers/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/js/controllers/index.js b/public/js/controllers/index.js index a45fa2f..d6e526e 100755 --- a/public/js/controllers/index.js +++ b/public/js/controllers/index.js @@ -33,7 +33,7 @@ angular.module('insight.system').controller('IndexController', var txStr = tx.txid.toString(); console.log('Transaction received! ' + JSON.stringify(tx)); if (parseInt($scope.txs.length, 10) > parseInt(TRANSACTION_DISPLAYED, 10) - 1) { - $scope.txs.pop(); + $scope.txs.slice(Math.max($scope.txs.length - TRANSACTION_DISPLAYED, 1)); } _getTransaction(txStr);