add safety check for username in github strategy

This commit is contained in:
Amruth Pillai
2024-03-10 10:27:30 +01:00
parent c8f7989c1f
commit ec77d13ebd

View File

@ -31,7 +31,7 @@ export class GitHubStrategy extends PassportStrategy(Strategy, "github") {
let user: User | null = null; let user: User | null = null;
if (!email) throw new BadRequestException(); if (!email || !username) throw new BadRequestException();
try { try {
const user = const user =