This commit is contained in:
Ivan Socolsky 2015-01-30 11:58:28 -03:00
parent 2890f94d52
commit 4cc20d682c
1 changed files with 2 additions and 0 deletions

View File

@ -41,6 +41,8 @@ function CopayServer(opts) {
CopayServer.prototype.createWallet = function (opts, cb) {
var self = this;
// TODO: validate opts.pubKey is valid and belongs to opts.network
self.storage.fetchWallet(opts.id, function (err, wallet) {
if (err) return cb(err);
if (wallet) return cb('Wallet already exists');