Yes, thanks pointing that out :) I need to change this too, because it seems the fix will only works for:
project group 1: Group project group 2: Group Two but not with this: project group 1: Group project group 2: My Group Thanks, -- Marica On Tue, Oct 27, 2009 at 2:08 AM, Brett Porter <[email protected]> wrote: > Isn't it also correct to say .endsWith( projectGroup.getName() ) ? > > Cheers, > Brett > > > On 15/10/2009, at 10:19 AM, [email protected] wrote: > > Author: ctan >> Date: Wed Oct 14 23:19:28 2009 >> New Revision: 825338 >> >> URL: http://svn.apache.org/viewvc?rev=825338&view=rev >> Log: >> [CONTINUUM-2387] retrieve correct roles to show only the users of the >> project group in the members tab >> >> Modified: >> >> continuum/branches/continuum-1.3.x/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java >> >> Modified: >> continuum/branches/continuum-1.3.x/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java >> URL: >> http://svn.apache.org/viewvc/continuum/branches/continuum-1.3.x/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java?rev=825338&r1=825337&r2=825338&view=diff >> >> ============================================================================== >> --- >> continuum/branches/continuum-1.3.x/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java >> (original) >> +++ >> continuum/branches/continuum-1.3.x/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectGroupAction.java >> Wed Oct 14 23:19:28 2009 >> @@ -689,7 +689,8 @@ >> List<String> roleNames = new ArrayList<String>(); >> for ( Role r : roles ) >> { >> - if ( r.getName().indexOf( projectGroup.getName() ) > -1 ) >> + int index = r.getName().indexOf( projectGroup.getName() >> ); >> + if ( index > -1 && r.getName().substring( index >> ).trim().equals( projectGroup.getName() ) ) >> { >> roleNames.add( r.getName() ); >> } >> >> >> >
