Skip to content

Commit

Permalink
Merge pull request #249 from eduNEXT/cag/nullable-type
Browse files Browse the repository at this point in the history
chore: remove unnecessary type checking
  • Loading branch information
Cristhian Garcia authored Nov 13, 2024
2 parents 9d91976 + b431b8a commit fc4c1ff
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions openedx_learning/apps/authoring/contents/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -267,11 +267,7 @@ class Content(models.Model):
# only in file form. It is an error for ``text`` to be None and ``has_file``
# to be False, since that would mean we haven't stored data anywhere at all.
#
# We annotate this because mypy doesn't recognize that ``text`` should be
# nullable when using MultiCollationTextField, but does the right thing for
# TextField. For more info, see:
# https://github.com/openedx/openedx-learning/issues/152
text: models.TextField[str | None, str | None] = MultiCollationTextField(
text = MultiCollationTextField(
blank=True,
null=True,
max_length=MAX_TEXT_LENGTH,
Expand Down

0 comments on commit fc4c1ff

Please sign in to comment.