Class: Sworn::ReplayProtector::Custom
- Inherits:
-
Object
- Object
- Sworn::ReplayProtector::Custom
- Defined in:
- lib/sworn/replay_protector/custom.rb
Instance Method Summary collapse
-
#initialize(*options) ⇒ Custom
constructor
A new instance of Custom.
- #replayed?(oauth) ⇒ Boolean
Constructor Details
#initialize(*options) ⇒ Custom
Returns a new instance of Custom.
4 5 6 |
# File 'lib/sworn/replay_protector/custom.rb', line 4 def initialize(*) @evaluator, _ = .flatten end |
Instance Method Details
#replayed?(oauth) ⇒ Boolean
8 9 10 |
# File 'lib/sworn/replay_protector/custom.rb', line 8 def replayed?(oauth) @evaluator.call(oauth) end |