diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2016-10-05 13:26:44 +0200 |
---|---|---|
committer | Eugen Rochko <eugen@zeonfederated.com> | 2016-10-05 13:26:44 +0200 |
commit | fe77921e4733b330e69a9f2db8be5de9ecefc8af (patch) | |
tree | 1c16f064097824740d3a2a80480b73f61e0d9afe /app/services | |
parent | b0788854141a98da8fc4da1dbbfaf2a3239e3760 (diff) |
Catching more exceptions that slipped through, removing AR logging from
production as it's very verbose and not very useful
Diffstat (limited to 'app/services')
-rw-r--r-- | app/services/fetch_atom_service.rb | 3 | ||||
-rw-r--r-- | app/services/fetch_remote_account_service.rb | 2 | ||||
-rw-r--r-- | app/services/fetch_remote_status_service.rb | 3 |
3 files changed, 8 insertions, 0 deletions
diff --git a/app/services/fetch_atom_service.rb b/app/services/fetch_atom_service.rb index 4be7f6355..f2625dcaa 100644 --- a/app/services/fetch_atom_service.rb +++ b/app/services/fetch_atom_service.rb @@ -12,6 +12,9 @@ class FetchAtomService < BaseService else return process_html(fetch(url)) end + + rescue OpenSSL::SSL::SSLError => e + Rails.logger.debug "SSL error: #{e}" end private diff --git a/app/services/fetch_remote_account_service.rb b/app/services/fetch_remote_account_service.rb index 5f45f9b28..83a81a61b 100644 --- a/app/services/fetch_remote_account_service.rb +++ b/app/services/fetch_remote_account_service.rb @@ -19,5 +19,7 @@ class FetchRemoteAccountService < BaseService Rails.logger.debug "Going to webfinger #{username}@#{domain}" return FollowRemoteAccountService.new.call("#{username}@#{domain}") + rescue Nokogiri::XML::XPath::SyntaxError + Rails.logger.debug "Invalid XML or missing namespace" end end diff --git a/app/services/fetch_remote_status_service.rb b/app/services/fetch_remote_status_service.rb index 24a63e841..a507fbeed 100644 --- a/app/services/fetch_remote_status_service.rb +++ b/app/services/fetch_remote_status_service.rb @@ -31,5 +31,8 @@ class FetchRemoteStatusService < BaseService Rails.logger.debug "Going to webfinger #{username}@#{domain}" return FollowRemoteAccountService.new.call("#{username}@#{domain}") + rescue Nokogiri::XML::XPath::SyntaxError + Rails.logger.debug "Invalid XML or missing namespace" + end end end |