Set thread id on parent status

This commit is contained in:
Mouse Reeve
2021-10-01 14:41:30 -07:00
parent 7ff040470f
commit 0cd55147ee
2 changed files with 18 additions and 4 deletions

View File

@ -76,6 +76,10 @@ class Status(OrderedCollectionPageMixin, BookWyrmModel):
super().save(*args, **kwargs)
if not self.reply_parent:
self.thread_id = self.id
super().save(broadcast=False, update_fields=["thread_id"])
def delete(self, *args, **kwargs): # pylint: disable=unused-argument
""" "delete" a status"""
if hasattr(self, "boosted_status"):