Feat: Dashboard accuracy, Staff & Settings modules, and File Auth fix

This commit is contained in:
Hamza-Ayed
2026-04-19 15:25:43 +03:00
parent 3acd9f261b
commit ef9baf33f7
7 changed files with 415 additions and 12 deletions

View File

@@ -18,7 +18,12 @@ export class JwtStrategy extends PassportStrategy(Strategy) {
private dataSource: DataSource,
) {
super({
jwtFromRequest: ExtractJwt.fromAuthHeaderAsBearerToken(),
jwtFromRequest: ExtractJwt.fromExtractors([
ExtractJwt.fromAuthHeaderAsBearerToken(),
(req) => {
return req.query ? (req.query as any).token : null;
},
]),
ignoreExpiration: false,
secretOrKey: configService.getOrThrow<string>('JWT_SECRET'),
});