Fix JSON payload being potentially mutated when processing interaction policies (#36392)

This commit is contained in:
Claire authored and GitHub committed 2025-10-08 12:31:51 +00:00
1 parent 6abda76d13
commit 987f1e897b
1 file changed
+1 -1
+1 -1
View File
@@ -142,7 +142,7 @@ class ActivityPub::Parser::StatusParser
def quote_subpolicy(subpolicy)
flags = 0
allowed_actors = as_array(subpolicy)
allowed_actors = as_array(subpolicy).dup
allowed_actors.uniq!
flags |= Status::QUOTE_APPROVAL_POLICY_FLAGS[:public] if allowed_actors.delete('as:Public') || allowed_actors.delete('Public') || allowed_actors.delete('https://www.w3.org/ns/activitystreams#Public')