Set report's reason to cascade deletion if the reason is deleted
Signed-off-by: Alek Ratzloff <alekratz@gmail.com>
This commit is contained in:
@@ -247,7 +247,7 @@ class Report(models.Model):
|
||||
# The report that was made by this user
|
||||
record = models.ForeignKey("ReportRecord", on_delete=models.CASCADE)
|
||||
# Reason for this report
|
||||
reason = models.ForeignKey("ReportReason", on_delete=models.SET_NULL, null=True)
|
||||
reason = models.ForeignKey("ReportReason", on_delete=models.CASCADE)
|
||||
# IP address of the reporter
|
||||
ip = models.GenericIPAddressField()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user