From 67d4b4da401edea5a9da1eb1a23c97064f82accc Mon Sep 17 00:00:00 2001 From: Nitwix Date: Sat, 12 Apr 2025 22:17:29 +0200 Subject: [PATCH] Make email validation less strict --- validation/from_account.py | 2 +- validation/from_profile.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/validation/from_account.py b/validation/from_account.py index a89546c..ac057d3 100644 --- a/validation/from_account.py +++ b/validation/from_account.py @@ -40,4 +40,4 @@ class FromAccount(BaseModel): raise ValueError(f'Ebanking name is different from account name') return self phone_number: str = Field(..., min_length=8) - email: EmailStr #TODO change ? \ No newline at end of file + email: str = Field(min_length=5) \ No newline at end of file diff --git a/validation/from_profile.py b/validation/from_profile.py index 40ae4e5..89b617f 100644 --- a/validation/from_profile.py +++ b/validation/from_profile.py @@ -24,7 +24,7 @@ class FromProfile(BaseModel): # Contact phone: str = Field(..., min_length=8) - email: EmailStr + email: str = Field(min_length=5) address: str # Personal info