Skip to content

Commit

Permalink
Template payload should be a UnifiedPayloadDrop, not a hash
Browse files Browse the repository at this point in the history
  • Loading branch information
benbalter committed Sep 6, 2017
1 parent d230d6d commit 3805012
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 8 deletions.
6 changes: 3 additions & 3 deletions lib/jekyll-seo-tag.rb
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,12 @@ def options
end

def payload
{
# site_payload is an instance of UnifiedPayloadDrop. See https://git.io/v5ajm
@payload ||= context.registers[:site].site_payload.merge({
"page" => context.registers[:page],
"site" => context.registers[:site].site_payload["site"],
"paginator" => context["paginator"],
"seo_tag" => drop,
}
})
end

def drop
Expand Down
4 changes: 0 additions & 4 deletions lib/jekyll-seo-tag/drop.rb
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,6 @@ def version
Jekyll::SeoTag::VERSION
end

def jekyll_version
Jekyll::VERSION
end

# Should the `<title>` tag be generated for this page?
def title?
return false unless title
Expand Down
2 changes: 1 addition & 1 deletion lib/template.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<title>{{ seo_tag.title }}</title>
{% endif %}

<meta name="generator" content="Jekyll v{{ seo_tag.jekyll_version }}" />
<meta name="generator" content="Jekyll v{{ jekyll.version }}" />

{% if seo_tag.page_title %}
<meta property="og:title" content="{{ seo_tag.page_title }}" />
Expand Down

0 comments on commit 3805012

Please sign in to comment.