summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lib/redmine/menu_manager.rb3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/redmine/menu_manager.rb b/lib/redmine/menu_manager.rb
index 0d2d19a43..3d19edce7 100644
--- a/lib/redmine/menu_manager.rb
+++ b/lib/redmine/menu_manager.rb
@@ -446,8 +446,7 @@ module Redmine
# it is considered an allowed node if at least one of the children is allowed
all_children = children
all_children += child_menus.call(project) if child_menus
- return true if all_children.detect{|child| child.allowed?(user, project) }
- return false
+ return false unless all_children.detect{|child| child.allowed?(user, project) }
elsif user && project
if permission
unless user.allowed_to?(permission, project)