Merge pull request #1922 from matiu/check/net

add network error handle
This commit is contained in:
Gustavo Maximiliano Cortez 2014-12-02 18:12:24 -03:00
commit 3b7bdafb04
1 changed files with 2 additions and 0 deletions

View File

@ -44,6 +44,8 @@ angular.module('copayApp.controllers').controller('HomeController', function($sc
copay.logger.warn(err);
if ((err.toString() || '').match('PNOTFOUND')) {
$scope.error = 'Invalid email or password';
} else if ((err.toString() || '').match('Connection')) {
$scope.error = 'Could not connect to Insight Server';
} else {
$scope.error = 'Unknown error';
}