Class: Authtown::Routes::InitRodauth
- Inherits:
-
Bridgetown::Rack::Routes
- Object
- Bridgetown::Rack::Routes
- Authtown::Routes::InitRodauth
- Defined in:
- lib/authtown/routes/rodauth.rb
Instance Method Summary collapse
Instance Method Details
#init_current_user ⇒ Object
23 24 25 26 27 28 29 30 |
# File 'lib/authtown/routes/rodauth.rb', line 23 def init_current_user Authtown::Current.user = if rodauth.logged_in? account_id = rodauth.account_from_session[:id] user_class = bridgetown_site.config.authtown.user_class_resolver.() user_class[account_id] end end |