diff options
author | Claire <claire.github-309c@sitedethib.com> | 2022-04-29 00:04:42 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-04-29 00:04:42 +0200 |
commit | 252deefe3433d0cedafd973becd0d85b5182eb49 (patch) | |
tree | e20d8fdf6a646d024206333e450fad06d5c4b535 /app/services/resolve_url_service.rb | |
parent | 78f7f23ad21359893cb022b7c2f7644d5c22cb43 (diff) | |
parent | 01c2f47b7f397af362504a64d850b0eed0b4575f (diff) |
Merge pull request #1757 from ClearlyClaire/glitch-soc/merge-upstream
Merge upstream changes
Diffstat (limited to 'app/services/resolve_url_service.rb')
-rw-r--r-- | app/services/resolve_url_service.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/app/services/resolve_url_service.rb b/app/services/resolve_url_service.rb index 5981e4d98..e2c745673 100644 --- a/app/services/resolve_url_service.rb +++ b/app/services/resolve_url_service.rb @@ -30,6 +30,11 @@ class ResolveURLService < BaseService end def process_url_from_db + if [500, 502, 503, 504, nil].include?(fetch_resource_service.response_code) + account = Account.find_by(uri: @url) + return account unless account.nil? + end + return unless @on_behalf_of.present? && [401, 403, 404].include?(fetch_resource_service.response_code) # It may happen that the resource is a private toot, and thus not fetchable, |