Skip to content

Commit ec77d13

Browse files
committed
add safety check for username in github strategy
1 parent c8f7989 commit ec77d13

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: apps/server/src/auth/strategy/github.strategy.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ export class GitHubStrategy extends PassportStrategy(Strategy, "github") {
3131

3232
let user: User | null = null;
3333

34-
if (!email) throw new BadRequestException();
34+
if (!email || !username) throw new BadRequestException();
3535

3636
try {
3737
const user =

0 commit comments

Comments
 (0)