Change site logo to expect a rooted url

This commit is contained in:
Bo Turnbow 2016-02-23 15:57:25 -07:00
parent b42501b45a
commit 2d0101bd1e
2 changed files with 3 additions and 3 deletions

View File

@ -84,7 +84,7 @@
{% endif %}
{% if page.image %}
<meta property="og:image" content="{{ page.image | prepend: "/" | prepend: seo_url | escape }}" />
<meta property="og:image" content="{{ page.image | prepend: seo_url | escape }}" />
{% endif %}
{% if page.date %}

View File

@ -111,10 +111,10 @@ describe Jekyll::SeoTag do
end
context 'with page.image' do
let(:page) { make_page('image' => 'foo.png') }
let(:page) { make_page('image' => '/img/foo.png') }
it 'outputs the image' do
expected = %r{<meta property="og:image" content="http://example.invalid/foo.png" />}
expected = %r{<meta property="og:image" content="http://example.invalid/img/foo.png" />}
expect(output).to match(expected)
end
end