add silent option.
This commit is contained in:
parent
304d9d6e77
commit
8e09b40257
|
@ -371,6 +371,7 @@ Bitcoin.prototype.getMiningInfo = function() {
|
|||
|
||||
Bitcoin.prototype.log =
|
||||
Bitcoin.prototype.info = function() {
|
||||
if (this.options.silent) return;
|
||||
if (typeof arguments[0] !== 'string') {
|
||||
var out = util.inspect(arguments[0], null, 20, true);
|
||||
return process.stdout.write('bitcoind.js: ' + out + '\n');
|
||||
|
@ -380,6 +381,7 @@ Bitcoin.prototype.info = function() {
|
|||
};
|
||||
|
||||
Bitcoin.prototype.error = function() {
|
||||
if (this.options.silent) return;
|
||||
if (typeof arguments[0] !== 'string') {
|
||||
var out = util.inspect(arguments[0], null, 20, true);
|
||||
return process.stderr.write('bitcoind.js: ' + out + '\n');
|
||||
|
|
Loading…
Reference in New Issue