|
|
@ -1,8 +1,8 @@ |
|
|
|
module.exports = (shepherd) => { |
|
|
|
shepherd.get('/electrum/login', (req, res, next) => { |
|
|
|
shepherd.post('/electrum/login', (req, res, next) => { |
|
|
|
for (let key in shepherd.electrumServers) { |
|
|
|
const _abbr = shepherd.electrumServers[key].abbr; |
|
|
|
const { priv, pub } = shepherd.seedToWif(req.query.seed, shepherd.findNetworkObj(_abbr), req.query.iguana); |
|
|
|
const { priv, pub } = shepherd.seedToWif(req.body.seed, shepherd.findNetworkObj(_abbr), req.body.iguana); |
|
|
|
|
|
|
|
shepherd.electrumKeys[_abbr] = { |
|
|
|
priv, |
|
|
@ -12,7 +12,7 @@ module.exports = (shepherd) => { |
|
|
|
|
|
|
|
shepherd.electrumCoins.auth = true; |
|
|
|
|
|
|
|
shepherd.log(JSON.stringify(shepherd.electrumKeys, null, '\t'), true); |
|
|
|
// shepherd.log(JSON.stringify(shepherd.electrumKeys, null, '\t'), true);
|
|
|
|
|
|
|
|
const successObj = { |
|
|
|
msg: 'success', |
|
|
|