Skip to content

Commit 4521c2a

Browse files
committed
[refactor] Migrate from deprecated Rack::File to Rack::Files
See rack/rack@626272b
1 parent a6433e9 commit 4521c2a

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/main/ruby/jruby/rack/error_app.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ class ErrorApp
3131
attr_reader :root
3232

3333
def initialize(root = nil)
34-
if defined?(::Rack::File) && root.is_a?(::Rack::File)
34+
if defined?(::Rack::Files) && root.is_a?(::Rack::Files)
3535
@root = root.root # backwards compatibility
3636
else
3737
@root = root.nil? ? JRuby::Rack.public_path : root

src/main/ruby/rack/adapter/rails.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ class Rails
1111
def initialize(options={})
1212
@root = options[:root] || Dir.pwd
1313
@public = options[:public] || ::File.join(@root, "public")
14-
@file_server = Rack::File.new(@public)
14+
@file_server = Rack::Files.new(@public)
1515
if defined?(ActionController::Dispatcher.middleware)
1616
@dispatcher = ActionController::Dispatcher.new
1717
else

0 commit comments

Comments
 (0)