mirror of https://github.com/BTCPrivate/copay.git
Merge pull request #51 from cmgustavo/bug/01-generateaddress
Fixed generateAddress in front-end...
This commit is contained in:
commit
072e55665d
|
@ -6,14 +6,13 @@ angular.module('copay.home').controller('HomeController',
|
|||
|
||||
$scope.oneAtATime = true;
|
||||
|
||||
if (!$rootScope.wallet.id) {
|
||||
if (!$rootScope.wallet || !$rootScope.wallet.id) {
|
||||
$location.path('signin');
|
||||
}
|
||||
|
||||
|
||||
|
||||
else {
|
||||
$scope.addrs = $rootScope.wallet.publicKeyRing.getAddresses();
|
||||
$scope.selectedAddr = $scope.addrs[0];
|
||||
}
|
||||
|
||||
$scope.newAddr = function() {
|
||||
var a = $rootScope.wallet.publicKeyRing.generateAddress();
|
||||
|
|
|
@ -29,13 +29,12 @@ Wallet.prototype._startInterface = function(config) {
|
|||
this.blockchain = new Blockchain(config.blockchain);
|
||||
|
||||
this.networkName = config.networkName;
|
||||
this.requiredCopayers = config.requiredCopayers;
|
||||
this.totalCopayers = config.totalCopayers;
|
||||
this.requiredCopayers = config.wallet.requiredCopayers;
|
||||
this.totalCopayers = config.wallet.totalCopayers;
|
||||
};
|
||||
|
||||
|
||||
Wallet.prototype.create = function(opts) {
|
||||
|
||||
this.id = opts.id || Wallet.getRandomId();
|
||||
this.log('### CREATING NEW WALLET.' + (opts.id ? ' USING ID: ' + opts.id : ' NEW ID'));
|
||||
|
||||
|
|
Loading…
Reference in New Issue