📈 Open source, privacy-first web analytics — a cookie-less Google Analytics alternative with built-in error tracking and performance monitoring. Self-host it or use our cloud. Get started for free!
TypeScript chartsclickhousedockergdprgoogle-analyticsmetricsmonitoringmysqlnestjsprivacyredisself-hostedselfhostedstatisticstailwindcssweb-analyticswebanalyticswebsite
remove refresh-token dependency
Blue Mousedcf2d10cf818
diff --git a/apps/production/src/auth/auth.controller.ts b/apps/production/src/auth/auth.controller.tsindex d850239c9..2e3b42568 100644--- a/apps/production/src/auth/auth.controller.ts+++ b/apps/production/src/auth/auth.controller.ts@@ -26,9 +26,9 @@ import {import { I18nValidationExceptionFilter, I18n, I18nContext } from 'nestjs-i18n'import * as _pick from 'lodash/pick'-import { checkRateLimit } from 'src/common/utils'-import { UserType, User } from 'src/user/entities/user.entity'-import { UserService } from 'src/user/user.service'+import { checkRateLimit } from '../common/utils'+import { UserType, User } from '../user/entities/user.entity'+import { UserService } from '../user/user.service'import { AuthService } from './auth.service'import { Public, CurrentUserId, CurrentUser, Roles } from './decorators'import {@@ -421,18 +421,15 @@ export class AuthController {await this.authService.logout(user.id, refreshToken)}- @ApiOperation({ summary: 'Logout from all devices' })+ @ApiOperation({ summary: 'Log out from all devices' })@ApiOkResponse({description: 'Logged out from all devices',})- @Public()@UseGuards(JwtRefreshTokenGuard)@Post('logout-all')@HttpCode(200)public async logoutAll(@CurrentUserId() userId: string,- @CurrentUser('refreshToken') refreshToken: string,- @I18n() i18n: I18nContext,): Promise<void> {const user = await this.userService.findUserById(userId)@@ -440,15 +437,6 @@ export class AuthController {throw new UnauthorizedException()}- const isRefreshTokenValid = await this.authService.checkRefreshToken(- user.id,- refreshToken,- )-- if (!isRefreshTokenValid) {- throw new ConflictException(i18n.t('auth.invalidRefreshToken'))- }-await this.authService.logoutAll(user.id)}