Fix missing default user icon (#4554)

If the avatar is not present, an empty string is returned.
Even then it is truthy, thus no icon is rendered.
pull/4559/head
Oliver Günther 8 years ago committed by GitHub
parent 3de8303361
commit f2dcd61437
  1. 2
      lib/redmine/menu_manager/top_menu_helper.rb

@ -87,7 +87,7 @@ module Redmine::MenuManager::TopMenuHelper
label_options: {
id: 'user-menu',
title: User.current.name,
class: (avatar ? '' : 'icon-user icon-context')
class: (avatar.present? ? '' : 'icon-user icon-context')
},
items: items,
options: { menu_item_class: 'last-child' }

Loading…
Cancel
Save