diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/banzai/filter/reference_unfold_filter.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/banzai/filter/reference_unfold_filter.rb b/lib/banzai/filter/reference_unfold_filter.rb index d8ed44a0e4e..70a485ba2ae 100644 --- a/lib/banzai/filter/reference_unfold_filter.rb +++ b/lib/banzai/filter/reference_unfold_filter.rb @@ -21,6 +21,8 @@ module Banzai def call @referables.each do |referable| + next unless referable.respond_to?(:to_reference) + pattern = /#{Regexp.escape(referable.to_reference)}/ @text.gsub!(pattern, referable.to_reference(@new_project)) end |