Fix forum topic creation

This commit is contained in:
2024-07-09 16:55:07 +02:00
committed by Bartuccio Antoine
parent c9e398b7ec
commit a8918ebe86
2 changed files with 26 additions and 1 deletions

View File

@ -390,6 +390,8 @@ class ForumMessage(models.Model):
)
def is_deleted(self):
if self.id is None:
return False
meta = self.metas.exclude(action="EDIT").order_by("-date").first()
if meta:
return meta.action == "DELETE"