debian-mirror-gitlab/lib/gitlab/middleware/static.rb

14 lines
257 B
Ruby
Raw Normal View History

2015-04-26 12:48:37 +05:30
module Gitlab
module Middleware
class Static < ActionDispatch::Static
UPLOADS_REGEX = /\A\/uploads(\/|\z)/.freeze
def call(env)
return @app.call(env) if env['PATH_INFO'] =~ UPLOADS_REGEX
super
end
end
end
end