초기 커밋
This commit is contained in:
11
app/utils/validators.py
Normal file
11
app/utils/validators.py
Normal file
@@ -0,0 +1,11 @@
|
||||
from __future__ import annotations
|
||||
|
||||
import re
|
||||
|
||||
|
||||
def is_valid_device_uid(uid: str) -> bool:
|
||||
return bool(re.match(r"^[a-zA-Z0-9_-]{3,100}$", uid))
|
||||
|
||||
|
||||
def is_valid_email(email: str) -> bool:
|
||||
return bool(re.match(r"^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$", email))
|
||||
Reference in New Issue
Block a user