({ email, password }: CreateAuthParams)
| 104 | return newAuth; |
| 105 | } |
| 106 | static async createAuth({ email, password }: CreateAuthParams) { |
| 107 | const salt = generateSalt(); |
| 108 | const hash = generateHash(password, salt); |
| 109 | |
| 110 | return prisma.auths.create({ |
| 111 | data: { |
| 112 | salt, |
| 113 | password: hash, |
| 114 | email: String(email).toLowerCase(), |
| 115 | }, |
| 116 | }); |
| 117 | } |
| 118 | static async upsertUser({ |
| 119 | isAdmin = false, |
| 120 | isBot = false, |
no test coverage detected