mirror of
https://github.com/perfect-panel/ppanel-web.git
synced 2026-02-06 03:30:25 -05:00
🐛 fix(auth): Update email verification logic to use domain suffix check
This commit is contained in:
parent
c0fb34fa50
commit
62662bb79c
@ -31,7 +31,7 @@ export default function RegisterForm({
|
||||
|
||||
const handleCheckUser = async (email: string) => {
|
||||
try {
|
||||
if (!auth.email.enable_verify) return true;
|
||||
if (!auth.email.enable_domain_suffix) return true;
|
||||
const domain = email.split('@')[1];
|
||||
const isValid = auth.email?.domain_suffix_list.split('\n').includes(domain || '');
|
||||
return isValid;
|
||||
|
||||
@ -31,7 +31,7 @@ export default function RegisterForm({
|
||||
|
||||
const handleCheckUser = async (email: string) => {
|
||||
try {
|
||||
if (!auth.email.enable_verify) return true;
|
||||
if (!auth.email.enable_domain_suffix) return true;
|
||||
const domain = email.split('@')[1];
|
||||
const isValid = auth.email?.domain_suffix_list.split('\n').includes(domain || '');
|
||||
return isValid;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user