mirror of
https://codeberg.org/timelimit/timelimit-server.git
synced 2025-10-04 10:19:26 +02:00
Remove old mail login API
This commit is contained in:
parent
249cf52971
commit
df2cdab180
1 changed files with 0 additions and 18 deletions
|
@ -29,24 +29,6 @@ import {
|
|||
export const createAuthRouter = (database: Database) => {
|
||||
const router = Router()
|
||||
|
||||
router.post('/send-mail-login-code', json(), async (req, res, next) => {
|
||||
try {
|
||||
if (!isSendMailLoginCodeRequest(req.body)) {
|
||||
throw new BadRequest()
|
||||
}
|
||||
|
||||
const { mailLoginToken } = await sendLoginCode({
|
||||
mail: req.body.mail,
|
||||
locale: req.body.locale,
|
||||
database
|
||||
})
|
||||
|
||||
res.json({ mailLoginToken })
|
||||
} catch (ex) {
|
||||
next(ex)
|
||||
}
|
||||
})
|
||||
|
||||
router.post('/send-mail-login-code-v2', json(), async (req, res, next) => {
|
||||
try {
|
||||
if (!isSendMailLoginCodeRequest(req.body)) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue