removed useless check for account existence

This commit is contained in:
tigerbot 2017-07-26 18:16:30 -06:00
parent cd1ff73eea
commit 7902dea5f3
1 changed files with 19 additions and 32 deletions

View File

@ -206,19 +206,6 @@ $(function () {
// TODO loading
email = $('.js-oauth3-email').val();
return OAUTH3.authn.loginMeta(CONFIG.directives, {email: email, mock: true}).then(function (userResults) {
if (!userResults.data.error) {
console.log('User exists:', userResults);
}
if (userResults.data.error) {
$('.js-authn-show').removeAttr('disabled');
console.warn('User does not exist:', email);
console.warn('User Results:', userResults);
//window.alert('userResults: ' + userResults.data.error_description || userResults.data.error.message);
//return;
}
return OAUTH3.authn.otp(CONFIG.directives, {email: email, mock: true}).then(function (otpResults) {
if (otpResults.data.error) {
@ -234,7 +221,6 @@ $(function () {
$('.js-user-email').text(email);
});
});
};
util.rememberDevice = function (ev) {
ev.preventDefault();
@ -303,6 +289,7 @@ $(function () {
console.error('scope results', err);
});
}, function (error) {
console.error(error);
$('.error-msg').text('Incorrect code');
});
};