Fix example and formatting issue.
This commit is contained in:
parent
f488f3ff62
commit
b1aac02078
|
@ -1,5 +1,7 @@
|
|||
#!/usr/bin/env node
|
||||
|
||||
'use strict';
|
||||
|
||||
/**
|
||||
* bitcoind.js example
|
||||
*/
|
||||
|
@ -9,10 +11,9 @@ process.title = 'bitcoind.js';
|
|||
/**
|
||||
* bitcoind
|
||||
*/
|
||||
var bitcoindjsConf = process.env('BITCOINDJS_DIR');
|
||||
|
||||
var bitcoind = require('../')({
|
||||
directory: '~/.libbitcoind-example'
|
||||
directory: process.env.BITCOINDJS_DIR || '~/.bitcoin'
|
||||
});
|
||||
|
||||
bitcoind.on('error', function(err) {
|
||||
|
|
|
@ -196,7 +196,8 @@ Bitcoin.prototype.start = function(options, callback) {
|
|||
bitcoindjs.start(options, function(err, status) {
|
||||
self._started = true;
|
||||
|
||||
// Poll for queued packet [sigint, sighup, sigquit].forEach(function(signal) {
|
||||
// Poll for queued packet
|
||||
[sigint, sighup, sigquit].forEach(function(signal) {
|
||||
process.on(signal.name, signal.listener = function() {
|
||||
if (process.listeners(signal.name).length > 1) {
|
||||
return;
|
||||
|
|
Loading…
Reference in New Issue