no more inheritance
This commit is contained in:
parent
dc0da3645a
commit
e478c621f2
|
@ -125,7 +125,7 @@ module Travis::Api
|
||||||
use Travis::Api::App::Middleware::Metriks
|
use Travis::Api::App::Middleware::Metriks
|
||||||
|
|
||||||
# make sure this is below ScopeCheck so we have the token
|
# make sure this is below ScopeCheck so we have the token
|
||||||
use Travis::Api::Attack
|
use Rack::Attack
|
||||||
|
|
||||||
# if this is a v3 API request, ignore everything after
|
# if this is a v3 API request, ignore everything after
|
||||||
use Travis::API::V3::OptIn
|
use Travis::API::V3::OptIn
|
||||||
|
|
|
@ -1,10 +1,7 @@
|
||||||
require 'rack/attack'
|
require 'rack/attack'
|
||||||
|
|
||||||
module Travis::Api
|
class Rack::Attack
|
||||||
class Attack < Rack::Attack
|
module RequestMixin
|
||||||
DalliProxy = Rack::Attack::DalliProxy # ?
|
|
||||||
|
|
||||||
module Request
|
|
||||||
TOKEN = 'travis.access_token'.freeze
|
TOKEN = 'travis.access_token'.freeze
|
||||||
Rack::Attack::Request.prepend(self)
|
Rack::Attack::Request.prepend(self)
|
||||||
|
|
||||||
|
@ -69,4 +66,3 @@ module Travis::Api
|
||||||
cache.store = ActiveSupport::Cache::MemoryStore.new
|
cache.store = ActiveSupport::Cache::MemoryStore.new
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user