Skip to content

Commit

Permalink
Use page social_image_url if present (forem#20779)
Browse files Browse the repository at this point in the history
  • Loading branch information
benhalpern authored Mar 20, 2024
1 parent c01964b commit 01b55c6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/views/pages/show.en.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,15 @@
<meta property="og:type" content="article" />
<meta property="og:url" content="<%= app_url(@page.path) %>" />
<meta property="og:title" content="<%= @page.title %><%= community_name %>" />
<meta property="og:image" content="<%= Settings::General.main_social_image %>">
<meta property="og:image" content="<%= @page.social_image_url || Settings::General.main_social_image %>">
<meta property="og:description" content="<%= @page.description %>" />
<meta property="og:site_name" content="<%= community_name %>" />

<meta name="twitter:card" content="summary_large_image">
<meta name="twitter:site" content="@<%= Settings::General.social_media_handles["twitter"] %>">
<meta name="twitter:title" content="<%= @page.title %><%= community_name %>">
<meta name="twitter:description" content="<%= @page.description %>">
<meta name="twitter:image:src" content="<%= Settings::General.main_social_image %>">
<meta name="twitter:image:src" content="<%= @page.social_image_url || Settings::General.main_social_image %>">
<% end %>

<main id="main-content">
Expand Down

0 comments on commit 01b55c6

Please sign in to comment.