Skip to content

Commit

Permalink
assert
Browse files Browse the repository at this point in the history
  • Loading branch information
adamchainz committed Aug 28, 2022
1 parent 5cd4c5b commit 8fe81b5
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/django_mysql/models/fields/sets.py
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,7 @@ def check(self, **kwargs: Any) -> list[checks.CheckMessage]:
and isinstance(self.base_field, CharField)
and self.size
):
assert self.base_field.max_length is not None
max_size = (
# The chars used
(self.size * (self.base_field.max_length))
Expand Down

0 comments on commit 8fe81b5

Please sign in to comment.