From a59b596a2bcf2501ea407fc4aba43c8a8dd7b5d0 Mon Sep 17 00:00:00 2001 From: Ben Balter Date: Tue, 22 Aug 2017 11:41:02 -0400 Subject: [PATCH] comment site_author_hash --- lib/jekyll-seo-tag/drop.rb | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/jekyll-seo-tag/drop.rb b/lib/jekyll-seo-tag/drop.rb index e5cd5f7..632c2d4 100644 --- a/lib/jekyll-seo-tag/drop.rb +++ b/lib/jekyll-seo-tag/drop.rb @@ -246,6 +246,10 @@ module Jekyll site_author_hash(author_string) || { "name" => author_string } end + # Given a string representing the current document's author, attempt + # to retrieve additional metadata from site.data.authors, if present + # + # Returns the author hash def site_author_hash(author_string) return unless site.data["authors"] && site.data["authors"].is_a?(Hash) author_hash = site.data["authors"][author_string]