Fixing functionality

This commit is contained in:
= 2019-09-02 09:42:24 -05:00
parent edb16382f3
commit 25ef7b5675
Signed by: kiichan
GPG key ID: 619DFD67F0976616
14 changed files with 76 additions and 27 deletions

View file

@ -4,7 +4,7 @@
return input.length > 0 ? input[0].value : null;
},
current_url = window.location.href,
sqrl_frequency = 1500,
sqrl_frequency = 2500,
sqrl_call = function() {
setTimeout(sqrl_handler, sqrl_frequency);
},
@ -29,6 +29,7 @@
var data = JSON.parse(this.responseText);
if (data.transaction_complete === true) {
if (data.redirect_to !== undefined) {
console.log(data.redirect_to);
window.location.href = data.redirect_to;
} else {
console.error('Server indicated that SQRL transaction is complete ' +
@ -44,6 +45,7 @@
try {
request.send(null);
} catch (exception) {
console.log("stopping requests due to error??");
// do not send anymore requests if error occurred
}
};