On reconnect do not redirect to 'receive' tab

This commit is contained in:
Ivan Socolsky 2014-09-19 11:27:48 -03:00
parent cf4f663fb0
commit dadf8396f5
1 changed files with 8 additions and 4 deletions

View File

@ -55,10 +55,13 @@ angular.module('copayApp.services')
});
w.on('ready', function(myPeerID) {
$rootScope.wallet = w;
if ($rootScope.pendingPayment) {
$location.path('send');
} else {
$location.path('receive');
if ($rootScope.initialConnection) {
$rootScope.initialConnection = false;
if ($rootScope.pendingPayment) {
$location.path('send');
} else {
$location.path('receive');
}
}
});
@ -137,6 +140,7 @@ angular.module('copayApp.services')
uriHandler.register();
$rootScope.unitName = config.unitName;
$rootScope.txAlertCount = 0;
$rootScope.initialConnection = true;
$rootScope.reconnecting = false;
$rootScope.isCollapsed = true;
$rootScope.$watch('txAlertCount', function(txAlertCount) {