1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-16 08:13:42 +00:00

Validation of forms

This commit is contained in:
Kyle Spearrin
2016-09-22 12:50:27 -04:00
parent 24db219dc3
commit 985dba1555
16 changed files with 74 additions and 11 deletions

View File

@@ -7,6 +7,11 @@
$scope.loginPromise = null;
$scope.login = function (model) {
if (!model.code) {
toastr.error('Verification code is required.');
return;
}
$scope.loginPromise = loginService.logInTwoFactor(model.code);
$scope.loginPromise.then(function () {
$state.go('tabs.vault', { animation: 'in-slide-left' });