diff --git a/src/txdb.js b/src/txdb.js index aff2784..bb5feae 100755 --- a/src/txdb.js +++ b/src/txdb.js @@ -54,3 +54,9 @@ TransactionDatabase.prototype.loadTransactions = function (txs) { TransactionDatabase.prototype.getTransactions = function () { return this.txs; }; + +TransactionDatabase.prototype.clear = function () { + this.txs = []; + this.txIndex = {}; + $(this).trigger('update'); +};