Skip to content

Commit

Permalink
fix!
Browse files Browse the repository at this point in the history
  • Loading branch information
timthedev07 committed Dec 29, 2023
1 parent 3c6332a commit b8beee4
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions app/src/lib/authoptions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,13 @@ export const authOptions: AuthOptions = {
async signIn({ user /**account, profile, email, credentials */ }) {
if (
process.env.NODE_ENV === "production" &&
(!(
user.email?.endsWith("@kcpupils.org") &&
user.email?.endsWith("@kings.education") &&
user.email?.endsWith("@kingsgroup.org")
) ||
!user.email)
(!user.email ||
!(
user.email.endsWith("@kcpupils.org") ||
user.email.endsWith("@kings.education") ||
user.email.endsWith("@kingsgroup.org") ||
user.email === "kcamathshub.testing@gmail.com"
))
) {
return false;
}
Expand Down

0 comments on commit b8beee4

Please sign in to comment.