@@ -12,21 +12,11 @@ export interface GroupsTeamsAuthorizerConfig<TContext extends SecurityContext =
12
12
identityType ?: string ;
13
13
14
14
/**
15
- * @deprecated Use `listGroupSlugs` instead.
15
+ * @deprecated Return group slugs from the `getIdentity` function instead.
16
16
* Get a group slug to load permissions from.
17
17
*/
18
18
getGroupSlug ?: ( context : TContext ) => Promise < GroupSlug > | GroupSlug ;
19
19
20
- /**
21
- * List group slugs to load permissions from.
22
- */
23
- listGroupSlugs ?: ( context : TContext ) => Promise < GroupSlug [ ] > | GroupSlug [ ] ;
24
-
25
- /**
26
- * List team slugs to load groups and ultimately permissions from.
27
- */
28
- listTeamSlugs ?: ( context : TContext ) => Promise < TeamSlug [ ] > | TeamSlug [ ] ;
29
-
30
20
/**
31
21
* If a security group is not found, try loading it from a parent tenant (default: true).
32
22
*/
@@ -65,11 +55,6 @@ export const listPermissionsFromGroupsAndTeams = async <
65
55
groupSlugs . push ( loadedGroupSlug ) ;
66
56
}
67
57
68
- if ( config . listGroupSlugs ) {
69
- const loadedGroupSlugs = await config . listGroupSlugs ( context ) ;
70
- groupSlugs . push ( ...loadedGroupSlugs ) ;
71
- }
72
-
73
58
if ( identity . group ) {
74
59
groupSlugs . push ( identity . group ) ;
75
60
}
@@ -80,11 +65,6 @@ export const listPermissionsFromGroupsAndTeams = async <
80
65
81
66
if ( wcp . canUseTeams ( ) ) {
82
67
// Load groups coming from teams.
83
- if ( config . listTeamSlugs ) {
84
- const loadedTeamSlugs = await config . listTeamSlugs ( context ) ;
85
- teamSlugs . push ( ...loadedTeamSlugs ) ;
86
- }
87
-
88
68
if ( identity . team ) {
89
69
teamSlugs . push ( identity . team ) ;
90
70
}
0 commit comments