This commit is contained in:
Christopher Jeffrey 2016-04-15 16:24:33 -07:00
parent fbc8af9d94
commit 8efef35828
No known key found for this signature in database
GPG Key ID: 8962AB9DE6666BBD
3 changed files with 9 additions and 9 deletions

View File

@ -15,11 +15,6 @@ var utils = require('./utils');
var assert = utils.assert;
var VerifyError = utils.VerifyError;
/**
* @event Chain#block
* @type {Block|MerkleBlock}
*/
/**
* Represents a blockchain.
* @exports Chain

View File

@ -251,6 +251,8 @@ Environment.prototype.ensurePrefix = function ensurePrefix() {
/**
* Output a debug message.
* @param {Object|String} obj
* @param {...String} args
* @example
* bcoin.debug('foo: %d', 10);
*/

View File

@ -1004,7 +1004,10 @@ utils._inspect = function _inspect(obj, color) {
*/
utils.format = function format(args, color) {
color = color ? process.stdout.isTTY : false;
color = color
? (process.stdout ? process.stdout.isTTY : true)
: false;
return typeof args[0] === 'object'
? utils._inspect(args[0], color) + '\n'
: util.format.apply(util, args) + '\n';
@ -1012,8 +1015,8 @@ utils.format = function format(args, color) {
/**
* Write a message to stdout (console in browser).
* @param {Object|String} str
* @param {Object|String} arg1
* @param {Object|String} obj
* @param {...String} args
*/
utils.print = function print() {
@ -1035,7 +1038,7 @@ utils.print = function print() {
/**
* Shallow merge between multiple objects.
* @param {Object} target
* @param {Object} obj1
* @param {...Object} args
* @returns {Object} target
*/