summaryrefslogtreecommitdiff
path: root/src/server/api/private
diff options
context:
space:
mode:
authorsyuilo <Syuilotan@yahoo.co.jp>2021-03-21 21:27:09 +0900
committersyuilo <Syuilotan@yahoo.co.jp>2021-03-21 21:27:09 +0900
commitc4c20bee7c58ea7330dbc890b9564bd100ac6e25 (patch)
tree2f73ce46b5f0abe1417dad110ffc23c53155a8fe /src/server/api/private
parentrefactor: Use Set (diff)
downloadsharkey-c4c20bee7c58ea7330dbc890b9564bd100ac6e25.tar.gz
sharkey-c4c20bee7c58ea7330dbc890b9564bd100ac6e25.tar.bz2
sharkey-c4c20bee7c58ea7330dbc890b9564bd100ac6e25.zip
wip #6441
Diffstat (limited to 'src/server/api/private')
-rw-r--r--src/server/api/private/signin.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/server/api/private/signin.ts b/src/server/api/private/signin.ts
index 7a5efc6cc9..d8f2e6d516 100644
--- a/src/server/api/private/signin.ts
+++ b/src/server/api/private/signin.ts
@@ -53,7 +53,7 @@ export default async (ctx: Koa.Context) => {
async function fail(status?: number, failure?: { error: string }) {
// Append signin history
- await Signins.save({
+ await Signins.insert({
id: genId(),
createdAt: new Date(),
userId: user.id,
@@ -198,7 +198,7 @@ export default async (ctx: Koa.Context) => {
const challengeId = genId();
- await AttestationChallenges.save({
+ await AttestationChallenges.insert({
userId: user.id,
id: challengeId,
challenge: hash(Buffer.from(challenge, 'utf-8')).toString('hex'),