Browse Source

Error: Authenticator has already been registered

pull/3/head
Reynir Björnsson 2 months ago
parent
commit
c825a21b19
  1. 7
      bin/template.ml

7
bin/template.ml

@ -102,7 +102,12 @@ let register_view origin user =
});
});
}).catch(function (err) {
alert("exception: " + err);
// XXX: only if the exception came from navigator.credentials.create()
if (err.name === "InvalidStateError") {
alert("authenticator already registered");
} else {
alert("exception: " + err);
}
window.location = "/";
});
});

Loading…
Cancel
Save