Skip to content

Commit

Permalink
Update ForeignKeys for Django 2.2 support
Browse files Browse the repository at this point in the history
  • Loading branch information
kaizoku committed Mar 18, 2020
1 parent ce2c58c commit 0fa6f01
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions problem_builder/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,10 +68,10 @@ class Share(models.Model):
to query for arbitrary anonymous user IDs. In order to make sharing work, we have
to store them here.
"""
shared_by = models.ForeignKey(User, related_name='problem_builder_shared_by')
shared_by = models.ForeignKey(User, on_delete=models.CASCADE, related_name='problem_builder_shared_by')
submission_uid = models.CharField(max_length=32)
block_id = models.CharField(max_length=255, db_index=True)
shared_with = models.ForeignKey(User, related_name='problem_builder_shared_with')
shared_with = models.ForeignKey(User, on_delete=models.CASCADE, related_name='problem_builder_shared_with')
notified = models.BooleanField(default=False, db_index=True)

class Meta(object):
Expand Down

0 comments on commit 0fa6f01

Please sign in to comment.