Fix #3984: Twitter: undefined method `first' for nil:NilClass.
Fix Sources::Strategies::Twitter#image_urls to return an empty array instead of nil when the tweet doesn't contain any images.
This commit is contained in:
@@ -67,6 +67,8 @@ class TwitterService
|
||||
extract_urls_for_status(tweet)
|
||||
elsif tweet.urls.any?
|
||||
extract_urls_for_card(tweet)
|
||||
else
|
||||
[]
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user