Module: Makara::Cookie
Constant Summary collapse
- IDENTIFIER =
'_mkra_stck'.freeze
- DEFAULT_OPTIONS =
{ path: "/", http_only: true }
- MAX_AGE_BUFFER =
5
Instance Method Summary collapse
Instance Method Details
#fetch(request) ⇒ Object
14 15 16 |
# File 'lib/makara/cookie.rb', line 14 def fetch(request) parse(request.[IDENTIFIER].to_s) end |
#store(context_data, headers, options = {}) ⇒ Object
18 19 20 21 22 |
# File 'lib/makara/cookie.rb', line 18 def store(context_data, headers, = {}) unless context_data.nil? Rack::Utils. headers, IDENTIFIER, (context_data, ) end end |