From c2e9435dde15ca9dd4624bfb5d5ed56b5741f0c2 Mon Sep 17 00:00:00 2001 From: Robert Speicher Date: Sun, 16 Apr 2017 16:15:50 +0000 Subject: Merge branch 'sh-fix-base-parser' into 'master' Fix regression in rendering Markdown references that do not exist Closes #30972 See merge request !10716 --- lib/banzai/reference_parser/base_parser.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'lib') diff --git a/lib/banzai/reference_parser/base_parser.rb b/lib/banzai/reference_parser/base_parser.rb index dabf71d6aeb..c2503fa2adc 100644 --- a/lib/banzai/reference_parser/base_parser.rb +++ b/lib/banzai/reference_parser/base_parser.rb @@ -136,7 +136,8 @@ module Banzai nodes.each_with_object({}) do |node, hash| if node.has_attribute?(attribute) - hash[node] = objects_by_id[node.attr(attribute).to_i] + obj = objects_by_id[node.attr(attribute).to_i] + hash[node] = obj if obj end end end -- cgit v1.2.1