Class: Rack::Pubcookie::Fake
- Inherits:
-
Object
- Object
- Rack::Pubcookie::Fake
- Defined in:
- lib/rack/pubcookie/fake.rb
Instance Method Summary collapse
- #call(env) ⇒ Object
-
#initialize(app, username) ⇒ Fake
constructor
A new instance of Fake.
Constructor Details
#initialize(app, username) ⇒ Fake
Returns a new instance of Fake.
5 6 7 |
# File 'lib/rack/pubcookie/fake.rb', line 5 def initialize app, username @app, @username = app, username end |
Instance Method Details
#call(env) ⇒ Object
9 10 11 12 |
# File 'lib/rack/pubcookie/fake.rb', line 9 def call env env['REMOTE_USER'] = @username @app.call env end |