From 8e30c05e3e3d08797bd2475726bcf8b7489eef6e Mon Sep 17 00:00:00 2001 From: olalonde Date: Mon, 21 Apr 2014 04:29:23 +0800 Subject: [PATCH] Electrum: removed dead code --- examples/ElectrumMPK.js | 19 +++++-------------- 1 file changed, 5 insertions(+), 14 deletions(-) diff --git a/examples/ElectrumMPK.js b/examples/ElectrumMPK.js index 8375fd8..c6bbb13 100644 --- a/examples/ElectrumMPK.js +++ b/examples/ElectrumMPK.js @@ -1,20 +1,11 @@ -var Key = require('../lib/Key'); +var Electrum = require('../lib/Electrum'); var Address = require('../lib/Address'); -var k = new Key(); - -//k.public = new Buffer('92eea4d2f5263651db9e3222caded1fd4c89772f79a7c03fb6afc00e9d2c9d2ed9b86c2c95fc1171e49163079dacb7f048b3c509a27a490e1df9e7128362d468', 'hex'); -//k.public = new Buffer('0492eea4d2f5263651db9e3222caded1fd4c89772f79a7c03fb6afc00e9d2c9d2ed9b86c2c95fc1171e49163079dacb7f048b3c509a27a490e1df9e7128362d468', 'hex'); -//k.public = new Buffer('0478d430274f8c5ec1321338151e9f27f4c676a008bdf8638d07c0b6be9ab35c71a1518063243acd4dfe96b66e3f2ec8013c8e072cd09b3834a19f81f659cc3455', 'hex'); -//k.generatePubKey(); -//debugger; -//console.log(k); -var Electrum = require('../lib/Electrum'); -//92eea4d2f5263651db9e3222caded1fd4c89772f79a7c03fb6afc00e9d2c9d2ed9b86c2c95fc1171e49163079dacb7f048b3c509a27a490e1df9e7128362d468 var mpk = '92eea4d2f5263651db9e3222caded1fd4c89772f79a7c03fb6afc00e9d2c9d2ed9b86c2c95fc1171e49163079dacb7f048b3c509a27a490e1df9e7128362d468'; + mpk = new Electrum(mpk); -var key1 = mpk.generatePubKey(0); -var addr1 = Address.fromPubKey(key1); +var key0 = mpk.generatePubKey(0); +var addr0 = Address.fromPubKey(key0); -console.log(addr1.as('base58')); +console.log(addr0.as('base58'));