noosfero | WIP: Rails 5.1.6 Upgrade (!1438)
Gabriel Silva
gitlab at mg.gitlab.com
Wed Oct 31 13:07:37 BRST 2018
Gabriel Silva started a new discussion on app/models/highlights_block.rb:
> i[:new_window] = i[:new_window] == '1' ? true : false
>
> uploaded_file = UploadedFile.find_by(id: i[:image_id])
> - i[:image_src] = uploaded_file.public_filename if uploaded_file.present?
> + i[:image_src] = if uploaded_file.present? then uploaded_file.public_filename else nil end
Change this inline if to a ternary operator.
--
Reply to this email directly or view it on GitLab: https://gitlab.com/noosfero/noosfero/merge_requests/1438#note_113533072
You're receiving this email because of your account on gitlab.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listas.softwarelivre.org/pipermail/noosfero-dev/attachments/20181031/4f999a12/attachment-0001.html>
More information about the Noosfero-dev
mailing list