1
0
Fork 0
mirror of https://github.com/sinatra/sinatra synced 2023-03-27 23:18:01 -04:00

Removed the double check line!

Removed the double check line!
This commit is contained in:
Orange Tsai 2018-02-11 02:29:14 +08:00 committed by GitHub
parent d17aa95f50
commit ba7af51bd7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1061,7 +1061,6 @@ module Sinatra
def static!(options = {})
return if (public_dir = settings.public_folder).nil?
path = File.expand_path("#{public_dir}#{URI_INSTANCE.unescape(request.path_info)}" )
return unless path.start_with?(public_dir)
return unless File.file?(path)
env['sinatra.static_file'] = path