Browse Source

add dependencies to event emitter

activeAddress
Ivan Socolsky 10 years ago
parent
commit
ef5a1acb72
  1. 9
      lib/server.js
  2. 1
      package.json

9
lib/server.js

@ -5,6 +5,8 @@ var $ = require('preconditions').singleton();
var async = require('async');
var log = require('npmlog');
log.debug = log.verbose;
var inherits = require('inherits');
var events = require('events');
var Bitcore = require('bitcore');
var PublicKey = Bitcore.PublicKey;
@ -33,6 +35,13 @@ function CopayServer(opts) {
this.storage = opts.storage || new Storage();
};
inherits(CopayServer, events.EventEmitter);
CopayServer._emit = function (event) {
var args = Array.prototype.slice.call(arguments);
log.debug('Emitting: ', args);
this.emit.apply(this, arguments);
};
/**
* Creates a new wallet.

1
package.json

@ -21,6 +21,7 @@
"bitcore": "^0.8.6",
"bitcore-explorers": "^0.9.1",
"express": "^4.10.0",
"inherits": "^2.0.1",
"leveldown": "^0.10.0",
"levelup": "^0.19.0",
"lodash": "^2.4.1",

Loading…
Cancel
Save