whoops, let's not break inital fetching
This commit is contained in:
parent
e7eb9adbf5
commit
54aa2c7ce3
1 changed files with 4 additions and 4 deletions
|
|
@ -80,10 +80,10 @@ class Webfinger
|
||||||
def get_hcard(webfinger_profile)
|
def get_hcard(webfinger_profile)
|
||||||
unless webfinger_profile.strip == ""
|
unless webfinger_profile.strip == ""
|
||||||
|
|
||||||
wf_profile = WebfingerProfile.new(@account, webfinger_profile)
|
@wf_profile = WebfingerProfile.new(@account, webfinger_profile)
|
||||||
|
|
||||||
begin
|
begin
|
||||||
hcard = RestClient.get(wf_profile.hcard, OPTS)
|
hcard = RestClient.get(@wf_profile.hcard, OPTS)
|
||||||
rescue
|
rescue
|
||||||
return I18n.t('webfinger.hcard_fetch_failed', :account => @account)
|
return I18n.t('webfinger.hcard_fetch_failed', :account => @account)
|
||||||
end
|
end
|
||||||
|
|
@ -96,8 +96,8 @@ class Webfinger
|
||||||
|
|
||||||
def make_person_from_webfinger(webfinger_profile)
|
def make_person_from_webfinger(webfinger_profile)
|
||||||
card = get_hcard(webfinger_profile)
|
card = get_hcard(webfinger_profile)
|
||||||
if card
|
if card && @wf_profile
|
||||||
p = Person.create_from_webfinger(wf_profile, card)
|
p = Person.create_from_webfinger(@wf_profile, card)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue