feat: passwords need 8 characters or more, on the Site and in the Kanban
All checks were successful
Build and deploy / Validate source (push) Successful in 7s
Build and deploy / Integration suite on a real stack (push) Successful in 3m28s
Build and deploy / Secret scan and release gate (push) Successful in 6s
Build and deploy / Publish images (push) Successful in 1m2s
All checks were successful
Build and deploy / Validate source (push) Successful in 7s
Build and deploy / Integration suite on a real stack (push) Successful in 3m28s
Build and deploy / Secret scan and release gate (push) Successful in 6s
Build and deploy / Publish images (push) Successful in 1m2s
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -361,7 +361,7 @@ $('fSenha').onsubmit=async event=>{
|
||||
event.preventDefault();
|
||||
try{await api('/account/password',{current:$('dAtual').value,new:$('dNova').value});
|
||||
$('dAtual').value='';$('dNova').value='';aviso('Senha alterada.');}
|
||||
catch(e){aviso(e.status===422?'A nova senha precisa ter 12 caracteres ou mais.':e.message,true);}
|
||||
catch(e){aviso(e.status===422?'A nova senha precisa ter 8 caracteres ou mais.':e.message,true);}
|
||||
};
|
||||
|
||||
// ---- Signing in ----------------------------------------------------------
|
||||
@@ -388,7 +388,7 @@ async function authenticate(path,body,destino){
|
||||
$('login').onsubmit=async event=>{event.preventDefault();try{await authenticate('/account/login',{email:$('email').value,password:$('password').value});}catch(e){aviso(e.message,true);}};
|
||||
$('register').onsubmit=async event=>{event.preventDefault();$('criarConta').disabled=true;
|
||||
try{await authenticate('/account/register',{customer:{name:$('register-name').value,cnpj:$('cnpj').value,zap:$('phone').value,mail:$('register-email').value},password:$('register-password').value});}
|
||||
catch(e){aviso(e.status===422?'Confira o nome, o CPF ou CNPJ, o WhatsApp e o e-mail. A senha precisa ter 12 caracteres ou mais.':e.message,true);}
|
||||
catch(e){aviso(e.status===422?'Confira o nome, o CPF ou CNPJ, o WhatsApp e o e-mail. A senha precisa ter 8 caracteres ou mais.':e.message,true);}
|
||||
finally{$('criarConta').disabled=false;}};
|
||||
|
||||
// Signup code: the account is created only once the code e-mailed to the
|
||||
@@ -460,7 +460,7 @@ $('fRedefinir').onsubmit=async event=>{
|
||||
if($('rNova').value!==$('rRepete').value){aviso('A nova senha e a repetição não conferem.',true);return;}
|
||||
try{await authenticate('/account/reset',{token:resetToken,password:$('rNova').value},'/conta');
|
||||
resetToken='';$('rNova').value='';$('rRepete').value='';aviso('Senha criada. Você já está na sua conta.');}
|
||||
catch(e){aviso(e.status===422?(resetToken?'A nova senha precisa ter 12 caracteres ou mais.':'Este link está incompleto. Peça outro em “Esqueci minha senha”.'):e.message,true);}
|
||||
catch(e){aviso(e.status===422?(resetToken?'A nova senha precisa ter 8 caracteres ou mais.':'Este link está incompleto. Peça outro em “Esqueci minha senha”.'):e.message,true);}
|
||||
};
|
||||
$('logout').onclick=async()=>{try{await window.dtfForgetPrivateData();await api('/account/logout',{});location.assign('/conta/entrar');}catch(error){aviso('Não foi possível limpar os dados deste navegador. Feche as abas do Site e limpe os dados do site nas configurações do navegador.',true);}};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user