Module: CompositionEngine
- Defined in:
- lib/composition_engine.rb
Defined Under Namespace
Classes: LoginHandler, Middleware, User
Constant Summary
collapse
- SESSION_KEY =
'composition_engine'
- PATH_PREFIX =
'/engine'
Class Method Summary
collapse
Class Method Details
.assign_user_to_session(session, user) ⇒ Object
7
8
9
|
# File 'lib/composition_engine.rb', line 7
def self.assign_user_to_session(session,user)
scope_session(session)['user'] = user
end
|
11
12
13
|
# File 'lib/composition_engine.rb', line 11
def self.(session)
scope_session(session)['user']
end
|
.scope_session(session) ⇒ Object
15
16
17
|
# File 'lib/composition_engine.rb', line 15
def self.scope_session(session)
session[SESSION_KEY]||= {}
end
|