Module: Sufia::CitationsBehaviors::CommonBehavior
- Included in:
- Sufia::CitationsBehavior, Formatters::BaseFormatter, NameBehavior, PublicationBehavior, TitleBehavior
- Defined in:
- app/helpers/sufia/citations_behaviors/common_behavior.rb
Instance Method Summary collapse
Instance Method Details
#clean_end_punctuation(text) ⇒ Object
8 9 10 11 12 13 |
# File 'app/helpers/sufia/citations_behaviors/common_behavior.rb', line 8 def clean_end_punctuation(text) if text && ([".", ",", ":", ";", "/"].include? text[-1, 1]) return text[0, text.length - 1] end text end |