2015-02-20 06:44:07 -05:00
|
|
|
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
|
2015-02-20 08:39:35 -05:00
|
|
|
end
|