fix: remove send email endpoint

This commit is contained in:
Abdalhamid Alhamad
2025-01-06 16:47:43 +03:00
parent 3ab0f179d8
commit ee433a5c8c

View File

@ -1,10 +1,9 @@
import { Body, Controller, Get, HttpCode, HttpStatus, Post, Query, UseGuards } from '@nestjs/common';
import { Controller, Get, HttpCode, HttpStatus, Post, Query, UseGuards } from '@nestjs/common';
import { ApiBearerAuth, ApiResponse, ApiTags } from '@nestjs/swagger';
import { IJwtPayload } from '~/auth/interfaces';
import { AuthenticatedUser } from '~/common/decorators';
import { AccessTokenGuard } from '~/common/guards';
import { PageOptionsRequestDto } from '~/core/dtos';
import { SendEmailRequestDto } from '../dtos/request';
import { NotificationsPageResponseDto } from '../dtos/response';
import { NotificationsService } from '../services/notifications.service';
@ -34,11 +33,4 @@ export class NotificationsController {
markAsRead(@AuthenticatedUser() { sub }: IJwtPayload) {
return this.notificationsService.markAsRead(sub);
}
@Post('email')
@UseGuards(AccessTokenGuard)
@HttpCode(HttpStatus.NO_CONTENT)
sendEmail(@AuthenticatedUser() { sub }: IJwtPayload, @Body() body: SendEmailRequestDto) {
return this.notificationsService.sendEmail(body);
}
}