This commit is contained in:
Christopher Jeffrey 2016-07-01 13:51:34 -07:00
parent 8541843e14
commit e0373dbf65
No known key found for this signature in database
GPG Key ID: 8962AB9DE6666BBD
14 changed files with 8 additions and 19 deletions

View File

@ -142,7 +142,7 @@ AsyncObject.prototype.destroy = AsyncObject.prototype.close;
AsyncObject.prototype._error = function _error(event, err) {
var listeners = this.listeners(event);
var i, callback;
var i;
this.removeAllListeners(event);

View File

@ -11,6 +11,7 @@ var utils = require('./utils');
var assert = utils.assert;
var constants = bcoin.protocol.constants;
var siphash = require('./siphash');
var bn = require('bn.js');
var AbstractBlock = bcoin.abstractblock;
/**

View File

@ -8,7 +8,6 @@
'use strict';
var bcoin = require('./env');
var EventEmitter = require('events').EventEmitter;
var AsyncObject = require('./async');
var constants = bcoin.protocol.constants;
var utils = require('./utils');
@ -56,8 +55,6 @@ var VerifyError = bcoin.errors.VerifyError;
*/
function Chain(options) {
var self = this;
if (!(this instanceof Chain))
return new Chain(options);
@ -1644,7 +1641,7 @@ Chain.prototype.purgeOrphans = function purgeOrphans() {
*/
Chain.prototype.pruneOrphans = function pruneOrphans() {
var i, hashes, orphan, height, best, last;
var i, hashes, hash, orphan, height, best, last;
hashes = Object.keys(this.orphan.map);
@ -2552,7 +2549,7 @@ DeploymentState.prototype.hasCLTV = function hasCLTV() {
*/
DeploymentState.prototype.hasMTP = function hasMTP() {
return (this.lockFlags & constants.flags.MEDIAN_TIME_PAST) !== 0
return (this.lockFlags & constants.flags.MEDIAN_TIME_PAST) !== 0;
};
/**

View File

@ -8,7 +8,6 @@
'use strict';
var bcoin = require('./env');
var EventEmitter = require('events').EventEmitter;
var AsyncObject = require('./async');
var constants = bcoin.protocol.constants;
var utils = require('./utils');

View File

@ -7,7 +7,6 @@
'use strict';
var EventEmitter = require('events').EventEmitter;
var AsyncObject = require('../async');
var utils = require('../utils');
var assert = utils.assert;

View File

@ -8,7 +8,6 @@
'use strict';
var bcoin = require('../env');
var EventEmitter = require('events').EventEmitter;
var AsyncObject = require('../async');
var utils = require('../utils');
var assert = utils.assert;

View File

@ -9,7 +9,6 @@
var utils = require('./utils');
var assert = utils.assert;
var EventEmitter = require('events').EventEmitter;
var AsyncObject = require('./async');
/**
@ -29,8 +28,6 @@ var AsyncObject = require('./async');
*/
function LowlevelUp(file, options) {
var self = this;
if (!(this instanceof LowlevelUp))
return new LowlevelUp(file, options);

View File

@ -13,7 +13,6 @@
*/
var bcoin = require('./env');
var EventEmitter = require('events').EventEmitter;
var AsyncObject = require('./async');
var constants = bcoin.protocol.constants;
var utils = require('./utils');

View File

@ -443,7 +443,7 @@ MinerBlock.prototype._init = function _init() {
// Create our merkle root.
this.updateMerkle();
}
};
utils.inherits(MinerBlock, EventEmitter);

View File

@ -177,7 +177,7 @@ MTX.prototype.addInput = function addInput(options, index) {
*/
MTX.prototype.addOutput = function addOutput(options, value) {
var options, output;
var output;
if ((options instanceof bcoin.wallet)
|| (options instanceof bcoin.keyring)) {

View File

@ -8,7 +8,6 @@
'use strict';
var bcoin = require('./env');
var EventEmitter = require('events').EventEmitter;
var AsyncObject = require('./async');
var utils = require('./utils');

View File

@ -80,7 +80,6 @@ var InvItem = bcoin.packets.InvItem;
*/
function Pool(options) {
var self = this;
var i, seeds, hostname, seed;
if (!(this instanceof Pool))

View File

@ -1574,6 +1574,7 @@ TXDB.prototype.hasTX = function hasTX(hash, callback) {
*/
TXDB.prototype.getCoin = function getCoin(hash, index, callback) {
var self = this;
var key = hash + '/' + index;
var coin = this.coinCache.get(key);
@ -1968,7 +1969,7 @@ WalletMap.prototype.toJSON = function toJSON() {
*/
WalletMap.prototype.fromJSON = function fromJSON(json) {
var i, j, table, account, input, output, path;
var i, j, table, input, output, path;
var hash, paths, hashes, accounts, values, key;
table = {};

View File

@ -17,7 +17,6 @@
*/
var bcoin = require('./env');
var EventEmitter = require('events').EventEmitter;
var AsyncObject = require('./async');
var utils = require('./utils');
var assert = utils.assert;