Alfresco JS

cancel
Showing results for 
Search instead for 
Did you mean: 
widadcadi
Active Member

Alfresco JS

hi

I have a code which allows to count the number of users for each given group, but the problem the execution of the script takes a lot of time, i don't know what it's the problem

 

var paging = utils.createPaging(-1, 0);
siteGroups = groups.getGroups(null, paging);
logger.log(siteGroups.length)

for (var i=0; i<siteGroups.length; i++) 
{ 
  logger.log(siteGroups[i].getUserCount());

}



 


}