Skip to content

Commit

Permalink
quick push
Browse files Browse the repository at this point in the history
  • Loading branch information
bnkc committed Aug 1, 2024
1 parent 873d56b commit 13ab9f2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions emv/validator.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ def __init__(
allow_empty_local: bool = False,
allow_quoted_local: bool = False,
allow_domain_literal: bool = False,
deliverable_address: bool = True,
):
"""
Initializes an EmailValidator object.
Expand All @@ -25,6 +26,7 @@ def __init__(
allow_empty_local,
allow_quoted_local,
allow_domain_literal,
deliverable_address,
)

def validate_email(self, email: Union[str, bytes]) -> ValidatedEmail:
Expand Down Expand Up @@ -61,6 +63,7 @@ def validate_email(
allow_empty_local: bool = False,
allow_quoted_local: bool = False,
allow_domain_literal: bool = False,
deliverable_address: bool = True,
) -> ValidatedEmail:
"""
Validates an email address with optional parameters.
Expand All @@ -85,5 +88,6 @@ def validate_email(
allow_empty_local,
allow_quoted_local,
allow_domain_literal,
deliverable_address,
)
return emv.validate_email(email)
2 changes: 1 addition & 1 deletion testing.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# from email_validator import EmailSyntaxError, validate_email, ValidatedEmail
from emv import validate_email

validate_email("\u0300@test")
print(validate_email("levostatnigrosh@gmail.com"))

0 comments on commit 13ab9f2

Please sign in to comment.