forked from mirrors/bookwyrm
Merge pull request #905 from mouse-reeve/shelve-action-serialization
Safer serialization of shelve and un-shelve activities
This commit is contained in:
commit
2c5f62e6cd
1 changed files with 2 additions and 2 deletions
|
@ -385,7 +385,7 @@ class CollectionItemMixin(ActivitypubMixin):
|
|||
object_field = getattr(self, self.object_field)
|
||||
collection_field = getattr(self, self.collection_field)
|
||||
return activitypub.Add(
|
||||
id=self.remote_id,
|
||||
id=self.get_remote_id(),
|
||||
actor=self.user.remote_id,
|
||||
object=object_field,
|
||||
target=collection_field.remote_id,
|
||||
|
@ -396,7 +396,7 @@ class CollectionItemMixin(ActivitypubMixin):
|
|||
object_field = getattr(self, self.object_field)
|
||||
collection_field = getattr(self, self.collection_field)
|
||||
return activitypub.Remove(
|
||||
id=self.remote_id,
|
||||
id=self.get_remote_id(),
|
||||
actor=self.user.remote_id,
|
||||
object=object_field,
|
||||
target=collection_field.remote_id,
|
||||
|
|
Loading…
Reference in a new issue