diff options
Diffstat (limited to 'app/services')
-rw-r--r-- | app/services/remove_status_service.rb | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/app/services/remove_status_service.rb b/app/services/remove_status_service.rb index 836b8fdc5..7aca24d12 100644 --- a/app/services/remove_status_service.rb +++ b/app/services/remove_status_service.rb @@ -53,7 +53,12 @@ class RemoveStatusService < BaseService end def unpush(type, receiver, status) - redis.zremrangebyscore(FeedManager.instance.key(type, receiver.id), status.id, status.id) + if status.reblog? + redis.zadd(FeedManager.instance.key(type, receiver.id), status.reblog_of_id, status.reblog_of_id) + else + redis.zremrangebyscore(FeedManager.instance.key(type, receiver.id), status.id, status.id) + end + FeedManager.instance.broadcast(receiver.id, type: 'delete', id: status.id) end |