Update activitylogs model
@@ -16,7 +16,7 @@ class ActivityLog(models.Model):
context = JSONField(help_text='Extra context information.')
created_at = models.DateTimeField()
- content_type = models.ForeignKey(ContentType, on_delete=models.SET_NULL)
+ content_type = models.ForeignKey(ContentType, on_delete=models.CASCADE)
object_id = models.PositiveIntegerField()
content_object = GenericForeignKey('content_type', 'object_id')
