Project

General

Profile

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

Seiei Miyagi, 2019-11-29 16:28

View differences:

app/controllers/application_controller.rb
644 644

  
645 645
  # Returns a string that can be used as filename value in Content-Disposition header
646 646
  def filename_for_content_disposition(name)
647
    return name unless request.env['HTTP_USER_AGENT']
648

  
647 649
    %r{(MSIE|Trident|Edge)}.match?(request.env['HTTP_USER_AGENT']) ? ERB::Util.url_encode(name) : name
648 650
  end
649 651

  
(2-2/2)