app/helpers/hyrax/citations_behaviors/common_behavior.rb in hyrax-2.1.0.beta1 vs app/helpers/hyrax/citations_behaviors/common_behavior.rb in hyrax-2.1.0.beta2
- old
+ new
@@ -4,12 +4,10 @@
def persistent_url(work)
"#{Hyrax.config.persistent_hostpath}#{work.id}"
end
def clean_end_punctuation(text)
- if text && ([".", ",", ":", ";", "/"].include? text[-1, 1])
- return text[0, text.length - 1]
- end
+ return text[0, text.length - 1] if text && ([".", ",", ":", ";", "/"].include? text[-1, 1])
text
end
end
end
end