File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -223,9 +223,9 @@ export default class SPPeopleSearchService {
223
223
searchBody . queryParams [ "SharePointGroupID" ] = groupId ;
224
224
}
225
225
226
- // Check if users need to be searched in a specific Office365 Group
226
+ // Check if users need to be searched in a specific Microsoft 365 Group, Security Group (incl. nested groups) or Distribution List
227
227
else if ( groupId && typeof ( groupId ) === 'string' ) {
228
- const graphUserRequestUrl = `/groups/${ groupId } /members ?$count=true&$search="displayName:${ query } " OR "mail:${ query } "` ;
228
+ const graphUserRequestUrl = `/groups/${ groupId } /transitiveMembers ?$count=true&$search="displayName:${ query } " OR "mail:${ query } "` ;
229
229
const graphClient = await this . context . msGraphClientFactory . getClient ( ) ;
230
230
const graphUserResponse = await graphClient . api ( graphUserRequestUrl ) . header ( 'ConsistencyLevel' , 'eventual' ) . get ( ) ;
231
231
You can’t perform that action at this time.
0 commit comments