fix: bug in the sliders and blog module
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { BadRequestException, Injectable, Logger } from "@nestjs/common";
|
||||
import { BadRequestException, Injectable } from "@nestjs/common";
|
||||
import { DataSource } from "typeorm";
|
||||
|
||||
import { TokensService } from "./tokens.service";
|
||||
@@ -17,7 +17,6 @@ import { VerifyOtpDto } from "../DTO/verify-otp.dto";
|
||||
|
||||
@Injectable()
|
||||
export class AuthService {
|
||||
private readonly logger = new Logger(AuthService.name);
|
||||
constructor(
|
||||
private readonly usersService: UsersService,
|
||||
private readonly passwordService: PasswordService,
|
||||
@@ -44,11 +43,9 @@ export class AuthService {
|
||||
const otpCode = await this.otpService.generateAndSetInCache(phone, "REGISTER");
|
||||
//
|
||||
await this.smsService.sendSmsVerifyCode(phone, otpCode);
|
||||
this.logger.debug(`OTP sent to ${phone}: ${otpCode}`);
|
||||
|
||||
return {
|
||||
message: AuthMessage.OTP_SENT,
|
||||
otpCode,
|
||||
};
|
||||
}
|
||||
//****************** */
|
||||
@@ -154,11 +151,9 @@ export class AuthService {
|
||||
const otpCode = await this.otpService.generateAndSetInCache(phone, "LOGIN");
|
||||
//
|
||||
await this.smsService.sendSmsVerifyCode(phone, otpCode);
|
||||
this.logger.debug(`OTP sent to ${phone}: ${otpCode}`);
|
||||
|
||||
return {
|
||||
message: AuthMessage.OTP_SENT,
|
||||
otpCode,
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user