Skip to content

Commit

Permalink
[maykinmedia/objects-api#481] Remove unused validation control
Browse files Browse the repository at this point in the history
  • Loading branch information
danielmursa-dev committed Dec 13, 2024
1 parent fd26732 commit dcecf53
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 7 deletions.
4 changes: 0 additions & 4 deletions src/objecttypes/token/tests/test_validators.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,3 @@ def test_tab_character_in_between(self):
def test_tab_characters_only(self):
with self.assertRaises(ValidationError):
validate_no_whitespace("\t\t")

def test_blank_value(self):
with self.assertRaises(ValidationError):
validate_no_whitespace("")
3 changes: 0 additions & 3 deletions src/objecttypes/token/validators.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,6 @@


def validate_no_whitespace(value: str) -> None:
if not value:
raise ValidationError(code="invalid", message=_("Blank values are not allowed"))

if WHITESPACE_PATTERN.match(value):
raise ValidationError(
code="all-whitespace",
Expand Down

0 comments on commit dcecf53

Please sign in to comment.