diff options
Diffstat (limited to 'app/services')
-rw-r--r-- | app/services/send_interaction_service.rb | 2 | ||||
-rw-r--r-- | app/services/subscribe_service.rb | 2 | ||||
-rw-r--r-- | app/services/unsubscribe_service.rb | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/app/services/send_interaction_service.rb b/app/services/send_interaction_service.rb index c11813abc..af205c9c9 100644 --- a/app/services/send_interaction_service.rb +++ b/app/services/send_interaction_service.rb @@ -12,7 +12,7 @@ class SendInteractionService < BaseService return if !target_account.ostatus? || block_notification? - delivery = build_request.perform + delivery = build_request.perform.flush raise Mastodon::UnexpectedResponseError, delivery unless delivery.code > 199 && delivery.code < 300 end diff --git a/app/services/subscribe_service.rb b/app/services/subscribe_service.rb index bfa7ff8c8..2d8af0203 100644 --- a/app/services/subscribe_service.rb +++ b/app/services/subscribe_service.rb @@ -6,7 +6,7 @@ class SubscribeService < BaseService @account = account @account.secret = SecureRandom.hex - @response = build_request.perform + @response = build_request.perform.flush if response_failed_permanently? # We're not allowed to subscribe. Fail and move on. diff --git a/app/services/unsubscribe_service.rb b/app/services/unsubscribe_service.rb index b99046712..d84a5a530 100644 --- a/app/services/unsubscribe_service.rb +++ b/app/services/unsubscribe_service.rb @@ -7,7 +7,7 @@ class UnsubscribeService < BaseService @account = account begin - @response = build_request.perform + @response = build_request.perform.flush Rails.logger.debug "PuSH unsubscribe for #{@account.acct} failed: #{@response.status}" unless @response.status.success? rescue HTTP::Error, OpenSSL::SSL::SSLError => e |