diff --git a/lib/jekyll/tags/post_url.rb b/lib/jekyll/tags/post_url.rb index 2d3e8f44..5b0d6479 100644 --- a/lib/jekyll/tags/post_url.rb +++ b/lib/jekyll/tags/post_url.rb @@ -59,7 +59,7 @@ eos def render(context) site = context.registers[:site] - site.posts.each do |p| + site.posts.docs.each do |p| if @post == p return p.url end @@ -68,9 +68,9 @@ eos # New matching method did not match, fall back to old method # with deprecation warning if this matches - site.posts.each do |p| + site.posts.docs.each do |p| if @post.deprecated_equality p - Jekyll::Deprecator.deprecation_message "A call to '{{ post_url #{name} }}' did not match " + + Jekyll::Deprecator.deprecation_message "A call to '{{ post_url #{@post.name} }}' did not match " + "a post using the new matching method of checking name " + "(path-date-slug) equality. Please make sure that you " + "change this tag to match the post's name exactly."