mirror of https://github.com/tootsuite/mastodon
Handle missing links in Webfinger response (#31030)
parent
c27d194eb2
commit
fa54b61216
|
@ -26,7 +26,7 @@ class Webfinger
|
|||
private
|
||||
|
||||
def links
|
||||
@links ||= @json['links'].index_by { |link| link['rel'] }
|
||||
@links ||= @json.fetch('links', []).index_by { |link| link['rel'] }
|
||||
end
|
||||
|
||||
def validate_response!
|
||||
|
|
Loading…
Reference in New Issue