import { PassportStrategy } from '@nestjs/passport'; import { AuthService } from '../services/auth.service'; import { Injectable } from '@nestjs/common'; import { Strategy } from 'passport-jwt'; @Injectable() export class LocalStrategy extends PassportStrategy(Strategy) { constructor(private authService: AuthService) { super({ usernameField: 'email', }); } }