diff options
| author | Adam Soltys <[email protected]> | 2023-02-06 23:20:08 -0800 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2023-02-06 23:20:19 -0800 |
| commit | 831877b74fdd62f96e1b385225b41e1415b13fba (patch) | |
| tree | a2f40f03f07af4d30d93a802a1c3417a6b95df21 /routes | |
| parent | 61b2836e61ea120a8c808cda315a7eaa53e567fa (diff) | |
| download | coinos-server-831877b74fdd62f96e1b385225b41e1415b13fba.tar.gz coinos-server-831877b74fdd62f96e1b385225b41e1415b13fba.zip | |
pin endpoint
Diffstat (limited to 'routes')
| -rw-r--r-- | routes/users.js | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/routes/users.js b/routes/users.js index ea4026b8..615e9d41 100644 --- a/routes/users.js +++ b/routes/users.js @@ -347,6 +347,10 @@ export default { res.send(await bcrypt.compare(password, user.password)); }, + async pin({ body: { pin }, user }, res) { + res.send(!user.pin || user.pin === pin); + }, + async otpsecret(req, res) { try { await requirePin(req); |
