Skip to content

Commit

Permalink
Fix social image order logic (#2645)
Browse files Browse the repository at this point in the history
  • Loading branch information
benhalpern committed May 1, 2019
1 parent 5890542 commit 7100eab
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions app/helpers/social_image_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@ def user_social_image_url(user)
end

def article_social_image_url(article)
return legacy_article_social_image(article) unless use_new_social_url?(article)

if (image = article.social_image || article.main_image || article.video_thumbnail_url)
return cl_image_path(image,
type: "fetch",
Expand All @@ -27,7 +25,7 @@ def article_social_image_url(article)
fetch_format: "auto",
sign_url: true)
end

return legacy_article_social_image(article) unless use_new_social_url?(article)
article_social_preview_url(article, format: :png)
end

Expand Down

0 comments on commit 7100eab

Please sign in to comment.