diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2016-09-20 02:43:20 +0200 |
---|---|---|
committer | Eugen Rochko <eugen@zeonfederated.com> | 2016-09-20 02:43:20 +0200 |
commit | 608a2bfffc9186e71d52e0916b54b0f513994db2 (patch) | |
tree | 3a2d900162a1fc62a0221c180404771d5c787bcc /lib | |
parent | a86f21cf90814ef0dd6e013202fb93ee83beca86 (diff) |
Upgrade to PubSubHubbub 0.4 (removing verify_token)
Diffstat (limited to 'lib')
-rw-r--r-- | lib/tasks/mastodon.rake | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/tasks/mastodon.rake b/lib/tasks/mastodon.rake index c75028ecb..872b33cdd 100644 --- a/lib/tasks/mastodon.rake +++ b/lib/tasks/mastodon.rake @@ -13,12 +13,13 @@ namespace :mastodon do task clear: :environment do Account.remote.without_followers.find_each do |a| Rails.logger.debug "PuSH unsubscribing from #{a.acct}" + begin a.subscription('').unsubscribe rescue HTTP::Error, OpenSSL::SSL::SSLError Rails.logger.debug "PuSH unsubscribing from #{a.acct} failed due to an HTTP or SSL error" ensure - a.update!(verify_token: '', secret: '', subscription_expires_at: nil) + a.update!(secret: '', subscription_expires_at: nil) end end end |