Class: Garner::Strategies::Context::Key::Jsonp
- Defined in:
- lib/garner/strategies/context/key/jsonp.rb
Class Method Summary collapse
-
.apply(identity, ruby_context = nil) ⇒ Garner::Cache::Identity
Strips JSONP parameters from the key.
- .field ⇒ Object
Class Method Details
.apply(identity, ruby_context = nil) ⇒ Garner::Cache::Identity
Strips JSONP parameters from the key.
15 16 17 18 19 20 21 22 |
# File 'lib/garner/strategies/context/key/jsonp.rb', line 15 def self.apply(identity, ruby_context = nil) key_hash = identity.key_hash return super unless key_hash[field] key_hash[field].delete('callback') key_hash[field].delete('_') identity end |
.field ⇒ Object
6 7 8 |
# File 'lib/garner/strategies/context/key/jsonp.rb', line 6 def self.field :request_params end |