Change internal streaming payloads to stringified IDs as well

Per
https://github.com/tootsuite/mastodon/pull/5019#issuecomment-330736452
we need these changes to send deleted status IDs as strings, not
integers.
pull/5019/head
aschmitz 2017-09-19 22:57:26 -05:00
parent 8b7e8dcba1
commit 591a9af356
2 changed files with 2 additions and 2 deletions

View File

@ -18,7 +18,7 @@ class BatchedRemoveStatusService < BaseService
@stream_entry_batches = []
@salmon_batches = []
@activity_json_batches = []
@json_payloads = statuses.map { |s| [s.id, Oj.dump(event: :delete, payload: s.id)] }.to_h
@json_payloads = statuses.map { |s| [s.id, Oj.dump(event: :delete, payload: s.id.to_s)] }.to_h
@activity_json = {}
@activity_xml = {}

View File

@ -4,7 +4,7 @@ class RemoveStatusService < BaseService
include StreamEntryRenderer
def call(status)
@payload = Oj.dump(event: :delete, payload: status.id)
@payload = Oj.dump(event: :delete, payload: status.id.to_s)
@status = status
@account = status.account
@tags = status.tags.pluck(:name).to_a