Comparing version 1.0.4 to 1.0.5
{ | ||
"name": "eosjs-api", | ||
"version": "1.0.4", | ||
"version": "1.0.5", | ||
"description": "Application programming interface to EOS blockchain nodes.", | ||
@@ -33,5 +33,5 @@ "scripts": { | ||
"camel-case": "^3.0.0", | ||
"eosjs-json": "^1.0.2", | ||
"eosjs-json": "^1.0.3", | ||
"isomorphic-fetch": "^2.2.1" | ||
} | ||
} |
@@ -22,2 +22,4 @@ module.exports = { | ||
const chainDate = new Date(info.head_block_time + 'Z') | ||
const refBlockNum = (info.head_block_number - 3) & 0xFFFF | ||
console.log('refBlockNum', refBlockNum) | ||
// Back-up 3 blocks to help avoid mini-forks. The getBlock call does not return | ||
@@ -29,7 +31,9 @@ // its own block id but the next block has 'previous'. | ||
const headers = Object.assign({ | ||
refBlockNum, | ||
refBlockPrefix: new Buffer(headBlockId, 'hex').readUInt32LE(4), | ||
expiration: expiration.toISOString().split('.')[0], | ||
tapos: new Buffer(headBlockId, 'hex').readUInt32LE(4), | ||
scope: [], | ||
messages: [], | ||
permissions: [], | ||
signatures: [] | ||
signatures: [], | ||
authorizations: [], | ||
}) | ||
@@ -36,0 +40,0 @@ callback(null, headers) |
Sorry, the diff of this file is not supported yet
38117
205
Updatedeosjs-json@^1.0.3