fix framer bug. witness format.

This commit is contained in:
Christopher Jeffrey 2016-06-22 03:28:00 -07:00
parent 4b1915ca49
commit 167e187fe0
No known key found for this signature in database
GPG Key ID: 8962AB9DE6666BBD
2 changed files with 8 additions and 4 deletions

View File

@ -639,7 +639,7 @@ Framer.witnessTX = function _witnessTX(tx, writer) {
*/
Framer.block = function _block(block, writer) {
return block.toNormal(block);
return block.toNormal(writer);
};
/**

View File

@ -543,9 +543,13 @@ Witness.fromString = function fromString(items) {
*/
Witness.format = function format(items) {
return items.map(function(chunk) {
return chunk.toString('hex');
}).join(' ');
var out = [];
var i;
for (i = 0; i < items.length; i++)
out.push(items[i].toString('hex'));
return out.join(' ');
};
/**