Project

General

Profile

Patch #32527 » 0001-Fix-ruby-2.7-warning-given-argument-is-nil-this-will.patch

Seiei Miyagi, 2019-11-28 18:10

View differences:

app/controllers/application_controller.rb
# Returns a string that can be used as filename value in Content-Disposition header
def filename_for_content_disposition(name)
%r{(MSIE|Trident|Edge)}.match?(request.env['HTTP_USER_AGENT']) ? ERB::Util.url_encode(name) : name
request.env['HTTP_USER_AGENT']&.match?(%r{(MSIE|Trident|Edge)}) ? ERB::Util.url_encode(name) : name
end
def api_request?
(1-1/2)