Sha256: f4d80cc1bca8a6979b7bc29e833115ecc070b87d89da17f357c9e59b5e3cb1b1
Contents?: true
Size: 524 Bytes
Versions: 1
Compression:
Stored size: 524 Bytes
Contents
module Grandstand class Session #:nodoc: all def initialize(app, session_key = '_session_id') @app = app @session_key = session_key end def call(env) if env['HTTP_USER_AGENT'] =~ /^(Adobe|Shockwave) Flash/ && env['PATH_INFO'] =~ /^\/grandstand\/galleries\/\d+\/images$/ params = Rack::Request.new(env).POST env['HTTP_COOKIE'] = [ @session_key, params.delete('session_key') ].join('=').freeze unless params['session_key'].nil? end @app.call(env) end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
grandstand-0.3.0 | lib/grandstand/session.rb |