mirror of
https://github.com/samsonjs/rack-attack.git
synced 2026-04-25 14:47:43 +00:00
Make cache & notifier attr_accessors
Easier config for non-rails apps
This commit is contained in:
parent
d50e779cdc
commit
9c4dccac48
2 changed files with 2 additions and 3 deletions
|
|
@ -7,8 +7,7 @@ module Rack::Attack
|
||||||
|
|
||||||
class << self
|
class << self
|
||||||
|
|
||||||
attr_reader :cache, :notifier
|
attr_accessor :cache, :notifier, :blacklisted_response, :throttled_response
|
||||||
attr_accessor :blacklisted_response, :throttled_response
|
|
||||||
|
|
||||||
def whitelist(name, &block)
|
def whitelist(name, &block)
|
||||||
self.whitelists[name] = Whitelist.new(name, block)
|
self.whitelists[name] = Whitelist.new(name, block)
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
module Rack
|
module Rack
|
||||||
module Attack
|
module Attack
|
||||||
VERSION = '1.0.0'
|
VERSION = '1.1.0'
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue