chore: lint + upgrade packages

This commit is contained in:
diced
2025-08-02 15:40:09 -07:00
parent c360235fa8
commit 2fd1007e4b
4 changed files with 1594 additions and 1299 deletions

View File

@@ -91,7 +91,7 @@ export default fastifyPlugin(
PATH,
{ preHandler: [userMiddleware], ...secondlyRatelimit(2) },
async (req, res) => {
const { files, favorite, folder } = req.body;
const { files } = req.body;
if (!files || !files.length) return res.badRequest('Cannot process transaction without files');

View File

@@ -4,7 +4,7 @@ import { User, userSelect } from '@/lib/db/models/user';
import { log } from '@/lib/logger';
import { generateKey, totpQrcode, verifyTotpCode } from '@/lib/totp';
import { userMiddleware } from '@/server/middleware/user';
import { FastifyReply } from 'fastify';
import { FastifyReply, FastifyRequest } from 'fastify';
import fastifyPlugin from 'fastify-plugin';
export type ApiUserMfaTotpResponse = User | { secret: string } | { secret: string; qrcode: string };
@@ -16,7 +16,7 @@ type Body = {
const logger = log('api').c('user').c('mfa').c('totp');
const totpEnabledMiddleware = (_, res: FastifyReply, next: () => void) => {
const totpEnabledMiddleware = (_: FastifyRequest, res: FastifyReply, next: () => void) => {
if (!config.mfa.totp.enabled) {
return res.badRequest('TOTP is disabled');
}