From b44f22c87fb7de202130f77bbea02aa1ae5a1a60 Mon Sep 17 00:00:00 2001 From: wltsmrz Date: Tue, 7 Jan 2014 10:17:58 -0800 Subject: [PATCH] Emit 'signed' event when transaction is resigned --- src/js/ripple/transaction.js | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/js/ripple/transaction.js b/src/js/ripple/transaction.js index 94b89f1f..7edf0eb7 100644 --- a/src/js/ripple/transaction.js +++ b/src/js/ripple/transaction.js @@ -289,13 +289,15 @@ Transaction.prototype.sign = function() { return this; } - var key = seed.get_key(this.tx_json.Account); - var sig = key.sign(hash, 0); - var hex = sjcl.codec.hex.fromBits(sig).toUpperCase(); + var key = seed.get_key(this.tx_json.Account); + var sig = key.sign(hash, 0); + var hex = sjcl.codec.hex.fromBits(sig).toUpperCase(); this.tx_json.TxnSignature = hex; this.previousSigningHash = hash; + this.emit('signed', this.hash()); + return this; };