various fixes

This commit is contained in:
Ivan Socolsky 2014-12-02 14:33:46 -03:00 committed by Matias Alejo Garcia
commit 19d1bde546
6 changed files with 19 additions and 19 deletions

View file

@ -62,7 +62,8 @@ angular.module('copayApp.controllers').controller('CreateController',
$scope.error = 'Could not create wallet: ' + err;
}
}
$rootScope.$digest()
$rootScope.$digest();
});
};
});

View file

@ -1,5 +0,0 @@
'use strict';
angular.module('copayApp.controllers').controller('CreateWalletController', function($scope, $rootScope) {
$rootScope.title = 'Create Wallet';
});

View file

@ -18,14 +18,14 @@ angular.module('copayApp.controllers').controller('HomeController', function($sc
$scope.done = function() {
$rootScope.starting = false;
setTimeout(function () { $rootScope.$digest(); }, 1);
$rootScope.$digest();
};
$scope.$on("$destroy", function(){
var iden = $rootScope.iden;
if (iden) {
iden.removeListener('newWallets', $scope.done );
iden.removeListener('newWallet', $scope.done );
iden.removeListener('noWallets', $scope.done );
}
});

View file

@ -1,7 +1,7 @@
'use strict';
angular.module('copayApp.controllers').controller('HomeWalletController',
function($scope, $rootScope) {
angular.module('copayApp.controllers').controller('HomeWalletController', function($scope, $rootScope) {
$scope.init = function() {
$rootScope.title = 'Home';
$scope.addr = _.last($rootScope.wallet.getReceiveAddresses());
@ -9,5 +9,5 @@ angular.module('copayApp.controllers').controller('HomeWalletController',
$rootScope.$watch('wallet', function() {
$scope.addr = _.last($rootScope.wallet.getReceiveAddresses());
});
}
);
};
});