PR review catches and cleanups

This commit is contained in:
tenthirtyone 2017-08-14 02:02:28 -04:00
parent e27c7bcf87
commit ba1333f84f
2 changed files with 1 additions and 20 deletions

View File

@ -146,9 +146,7 @@ module.exports = function transactionAPI(router) {
if (err) {
res.status(501).send();
logger.log('err', err);
}
if (block[0]) {
} else if (block[0]) {
const b = block[0];
res.json({
pagesTotal: 1,

View File

@ -7,30 +7,13 @@ const logger = require('../logger');
function parse(entry, txs) {
txs.forEach((tx) => {
//const txJSON = tx.toJSON();
tx.outputs.forEach((output) => {
const outputJSON = output.toJSON();
/*
return new OutputModel({
address: outputJSON.address,
script: outputJSON.script,
value: outputJSON.value,
});*/
});
tx.inputs.forEach((input) => {
const inputJSON = input.toJSON();
/* return new InputModel({
prevout: inputJSON.prevout,
script: inputJSON.script,
witness: inputJSON.witness,
sequence: inputJSON.sequence,
address: inputJSON.address,
});
})*/
});
});
}