forked from mirrors/bookwyrm
Merge pull request #982 from bookwyrm-social/flower-errors
Flower errors
This commit is contained in:
commit
7bad8ac354
2 changed files with 4 additions and 3 deletions
|
@ -176,7 +176,8 @@ class Remove(Add):
|
|||
def action(self):
|
||||
""" find and remove the activity object """
|
||||
obj = self.object.to_model(save=False, allow_create=False)
|
||||
obj.delete()
|
||||
if obj:
|
||||
obj.delete()
|
||||
|
||||
|
||||
@dataclass(init=False)
|
||||
|
|
|
@ -155,8 +155,8 @@ class ActivitypubMixins(TestCase):
|
|||
|
||||
recipients = ActivitypubMixin.get_recipients(mock_self)
|
||||
self.assertEqual(len(recipients), 2)
|
||||
self.assertEqual(recipients[0], another_remote_user.inbox)
|
||||
self.assertEqual(recipients[1], self.remote_user.inbox)
|
||||
self.assertTrue(another_remote_user.inbox in recipients)
|
||||
self.assertTrue(self.remote_user.inbox in recipients)
|
||||
|
||||
def test_get_recipients_direct(self, _):
|
||||
""" determines the recipients for a user's object broadcast """
|
||||
|
|
Loading…
Reference in a new issue