Method: Marty::AuthApp#menu
- Defined in:
- app/components/marty/auth_app.rb
#menu ⇒ Object
Set the Logout button if current_user is set
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 |
# File 'app/components/marty/auth_app.rb', line 11 def [].tap do || user = Mcfly.whodunnit if !user.nil? << "->" << { text: user.name, tooltip: 'Current user', menu: , name: "sign_out", } else << "->" << :sign_in end end end |