about summary refs log tree commit diff
path: root/app/services/resolve_account_service.rb
diff options
context:
space:
mode:
authorClaire <claire.github-309c@sitedethib.com>2021-03-02 12:06:58 +0100
committerClaire <claire.github-309c@sitedethib.com>2021-03-02 12:06:58 +0100
commitd8fdbb054e30f6e8e505bce63e5f150bf117cd8e (patch)
tree0a671ee6c8a7644e6613dd87798f661f4703e8fe /app/services/resolve_account_service.rb
parent4aa860b65bd796b09dc0ceffa1fdd7de31060a34 (diff)
parent65db2625508c220fd3c0a1f37cdd2e13b6e02987 (diff)
Merge branch 'main' into glitch-soc/merge-upstream
Conflicts:
- `app/validators/status_length_validator.rb`:
  Upstream changes too close to glitch-soc MAX_CHARS changes, but not a real
  conflict.
  Applied upstream changes.
- `package.json`:
  glitch-soc-only dependency textually too close to a dependency updated
  upstream, not a real conflict.
  Applied upstream changes.
Diffstat (limited to 'app/services/resolve_account_service.rb')
-rw-r--r--app/services/resolve_account_service.rb5
1 files changed, 3 insertions, 2 deletions
diff --git a/app/services/resolve_account_service.rb b/app/services/resolve_account_service.rb
index 3301aaf51..b8ddeb2ad 100644
--- a/app/services/resolve_account_service.rb
+++ b/app/services/resolve_account_service.rb
@@ -10,7 +10,7 @@ class ResolveAccountService < BaseService
   # @param [String, Account] uri URI in the username@domain format or account record
   # @param [Hash] options
   # @option options [Boolean] :redirected Do not follow further Webfinger redirects
-  # @option options [Boolean] :skip_webfinger Do not attempt to refresh account data
+  # @option options [Boolean] :skip_webfinger Do not attempt any webfinger query or refreshing account data
   # @return [Account]
   def call(uri, options = {})
     return if uri.blank?
@@ -120,8 +120,9 @@ class ResolveAccountService < BaseService
 
   def webfinger_update_due?
     return false if @options[:check_delivery_availability] && !DeliveryFailureTracker.available?(@domain)
+    return false if @options[:skip_webfinger]
 
-    @account.nil? || ((!@options[:skip_webfinger] || @account.ostatus?) && @account.possibly_stale?)
+    @account.nil? || (@account.ostatus? && @account.possibly_stale?)
   end
 
   def activitypub_ready?