Skip to content

Commit

Permalink
remove perm check on internal findTokensForIdentity (#18708)
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexTugarev authored Sep 13, 2023
1 parent 258651f commit 33cd3cb
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions components/server/src/user/user-service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -94,11 +94,6 @@ export class UserService {

async findTokensForIdentity(userId: string, identity: Identity): Promise<TokenEntry[]> {
const result = await this.userDb.findTokensForIdentity(identity);
for (const token of result) {
if (!(await this.authorizer.hasPermissionOnUser(userId, "read_info", token.uid))) {
throw new ApplicationError(ErrorCodes.NOT_FOUND, "not found");
}
}
return result;
}

Expand Down

0 comments on commit 33cd3cb

Please sign in to comment.