mirror of https://github.com/apache/archiva.git
try all impls for returning a role
git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1433742 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
772cf2af87
commit
73840256b0
|
@ -110,8 +110,16 @@ public class ArchivaRbacManager
|
|||
public Role getRole( String roleName )
|
||||
throws RbacObjectNotFoundException, RbacManagerException
|
||||
{
|
||||
// iterate until not null ?
|
||||
return getRbacManagerForCommon().getRole( roleName );
|
||||
for ( RBACManager rbacManager : rbacManagersPerId.values() )
|
||||
{
|
||||
Role role = rbacManager.getRole( roleName );
|
||||
if ( role != null )
|
||||
{
|
||||
return role;
|
||||
}
|
||||
}
|
||||
log.debug( "cannot find role for name: ‘{}", roleName );
|
||||
return null;
|
||||
}
|
||||
|
||||
public List<Role> getAllRoles()
|
||||
|
|
Loading…
Reference in New Issue