<%
  if @in_pro_area
    _site_name = pro_site_name
    opengraph_logo = if theme_asset_exists?('images/logo-opengraph-pro.png')
      'logo-opengraph-pro.png'
    else
      'logo-opengraph.png'
    end
    default_title = _('A powerful, fully-featured FOI toolkit for journalists')
  else
    _site_name = site_name
    opengraph_logo = 'logo-opengraph.png'
    default_title = _('Make and browse Freedom of Information (FOI) requests')
  end
%>

<meta property="og:site_name" content="<%= _site_name %>" />

<% if @title %>
  <meta property="og:title" content="<%= @title %>" />
  <meta property="og:type" content="article" />
<% else %>
  <meta property="og:title" content="<%= default_title %>" />
  <meta property="og:type" content="website" />
<% end %>

<%= content_for :open_graph_tags %>

<meta property="og:image" content="<%= "#{request.protocol}#{request.host_with_port}#{asset_path(opengraph_logo)}" %>" />
<meta property="og:url" content="<%= request.original_url.force_encoding('utf-8') %>" />
<meta property="og:image:width" content="256" />
<meta property="og:image:height" content="256" />

Copy across (unchanged) file from main app
Copy across (unchanged) file from main app
