mirror of
https://github.com/docmost/docmost.git
synced 2026-08-29 01:37:05 +08:00
fix: cleanup consent
This commit is contained in:
@@ -51,7 +51,7 @@ export class JwtAuthGuard extends AuthGuard('jwt') {
|
||||
[ctx.getHandler(), ctx.getClass()],
|
||||
);
|
||||
if (requiresSession && user.authType !== JwtType.ACCESS) {
|
||||
this.logger.warn(
|
||||
this.logger.debug(
|
||||
`session-only endpoint ${ctx.getClass()?.name}.${ctx.getHandler()?.name} refused authType ${user.authType}`,
|
||||
);
|
||||
throw new ForbiddenException(
|
||||
|
||||
@@ -92,7 +92,7 @@ export class JwtStrategy extends PassportStrategy(Strategy, 'jwt') {
|
||||
this.sessionActivityService.trackActivity(sessionId, payload.sub, payload.workspaceId);
|
||||
}
|
||||
|
||||
return { user, workspace };
|
||||
return { user, workspace, authType: JwtType.ACCESS };
|
||||
}
|
||||
|
||||
private async validateApiKey(req: any, payload: JwtApiKeyPayload) {
|
||||
|
||||
+1
-1
Submodule apps/server/src/ee updated: 70fdfb9933...acae98e819
Reference in New Issue
Block a user