mirror of
https://git.ari.lt/ari.lt/ari.lt.git
synced 2025-02-04 17:49:24 +01:00
update @ Sat 30 Apr 22:45:27 EEST 2022
Signed-off-by: Ari Archer <ari.web.xyz@gmail.com>
This commit is contained in:
parent
d9de66c471
commit
fe30307229
1 changed files with 12 additions and 1 deletions
|
@ -1,8 +1,18 @@
|
|||
"use strict";
|
||||
|
||||
let user_canceled = false;
|
||||
|
||||
function pprompt(message) {
|
||||
if (user_canceled) return;
|
||||
|
||||
let value = prompt(message);
|
||||
return value ? value : pprompt(message);
|
||||
|
||||
if (value === null) {
|
||||
user_canceled = true;
|
||||
return;
|
||||
}
|
||||
|
||||
return value.replaceAll(" ", "") ? value : pprompt(message);
|
||||
}
|
||||
|
||||
async function user_account_create() {
|
||||
|
@ -27,6 +37,7 @@ async function user_account_create() {
|
|||
|
||||
if (!valid) {
|
||||
if (
|
||||
!user_canceled &&
|
||||
confirm(
|
||||
"The credentials you entered are not valid (password/username too short or the password don't match), try again?"
|
||||
)
|
||||
|
|
Loading…
Add table
Reference in a new issue