Commit 4b86cd70 authored by jplang's avatar jplang

Don't skip condition if defined (#15880).

git-svn-id: https://svn.redmine.org/redmine/trunk@15507 e93f8b46-1217-0410-a6f0-8f06a7374b81
parent 367481c5
......@@ -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)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment