app/helpers/ecm/downloads/download_helper.rb in ecm_downloads2-5.0.1 vs app/helpers/ecm/downloads/download_helper.rb in ecm_downloads2-5.0.2
- old
+ new
@@ -3,17 +3,13 @@
def render_download(download_name, _options = {})
download = Download.where(name: download_name).first.decorate
if download.nil?
I18n.t('ecm.downloads.download.messages.not_found', name: download_name)
else
- begin
- o = Ecm::Downloads::Configuration.prevent_textile_rendering_in_html ? '<notextile>' : ''
- o << render(download)
- o << '</notextile>' if Ecm::Downloads::Configuration.prevent_textile_rendering_in_html
- return o.html_safe
- rescue => e
- raise e
- end
+ o = Ecm::Downloads::Configuration.prevent_textile_rendering_in_html ? '<notextile>' : ''
+ o << render(download)
+ o << '</notextile>' if Ecm::Downloads::Configuration.prevent_textile_rendering_in_html
+ return o.html_safe
end
end
end
end