diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index e2baecede64f1b1a4a71e6bf5cbdfbef1229701d..e0105ee54f9b377597cb013bb6a95fe209cc37da 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -30,7 +30,7 @@ module ApplicationHelper if domain == Rails.configuration.x.local_domain account = Account.find_local(username) else - account = Account.find_by(username: username, domain: domain) + account = Account.find_remote(username, domain) end account diff --git a/app/services/follow_remote_account_service.rb b/app/services/follow_remote_account_service.rb index 01e07e2e9827da485a9eda639529e70c22f2cd5a..f056684201dab644d6a105bdf6ec4c07b188a758 100644 --- a/app/services/follow_remote_account_service.rb +++ b/app/services/follow_remote_account_service.rb @@ -10,7 +10,7 @@ class FollowRemoteAccountService < BaseService return Account.find_local(username) if domain == Rails.configuration.x.local_domain - account = Account.find_by(username: username, domain: domain) + account = Account.find_remote(username, domain) if account.nil? account = Account.new(username: username, domain: domain)