Method: MODL::Parser::Parsed.additional_string_processing

Defined in:
lib/modl/parser/parsed.rb

.additional_string_processing(text) ⇒ Object



46
47
48
49
50
51
52
53
54
# File 'lib/modl/parser/parsed.rb', line 46

def self.additional_string_processing(text)
  text = Substitutions.process text
  # Special case for a possibly empty graved string ``
  unless text.nil?
    match_data = /^`([^`]*)`$/.match text
    return match_data[1] if match_data&.length&.positive?
  end
  text
end