Refactor monkey-patching of Goldfinger (#12561)
This commit is contained in:
parent
4a2ea2e51b
commit
4b766f9846
6 changed files with 40 additions and 20 deletions
|
@ -3,6 +3,7 @@
|
|||
class RemoteFollow
|
||||
include ActiveModel::Validations
|
||||
include RoutingHelper
|
||||
include WebfingerHelper
|
||||
|
||||
attr_accessor :acct, :addressable_template
|
||||
|
||||
|
@ -71,7 +72,7 @@ class RemoteFollow
|
|||
end
|
||||
|
||||
def acct_resource
|
||||
@acct_resource ||= Goldfinger.finger("acct:#{acct}")
|
||||
@acct_resource ||= webfinger!("acct:#{acct}")
|
||||
rescue Goldfinger::Error, HTTP::ConnectionError
|
||||
nil
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue