Merge pull request #685 from mlorb/ml_sci_1373

Fix bug with audit trail - ajax error [SCI-1373]
This commit is contained in:
mlorb 2017-06-14 17:59:34 +02:00 committed by GitHub
commit 6e203d2f15

View file

@ -246,7 +246,11 @@ module ApplicationHelper
if !prefix.empty? &&
!prefix.include?('http://') &&
!prefix.include?('https://')
prefix = request.ssl? ? "https://#{prefix}" : "http://#{prefix}"
prefix = if respond_to?(:request) && request.ssl?
"https://#{prefix}"
else
"http://#{prefix}"
end
end
unless user.avatar(style) == '/images/icon_small/missing.png'