From 95564a34c55c82fe4fb19df96230f361149d4467 Mon Sep 17 00:00:00 2001 From: David Ernst Date: Mon, 5 Jan 2026 23:43:10 -0800 Subject: [PATCH] /api/malware-check/download: Remove unnecessary typing --- pages/api/malware-check/download.ts | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/pages/api/malware-check/download.ts b/pages/api/malware-check/download.ts index 58fdf96a..925f613b 100644 --- a/pages/api/malware-check/download.ts +++ b/pages/api/malware-check/download.ts @@ -1,5 +1,4 @@ import { NextApiRequest, NextApiResponse } from 'next' -import { CipherStrings } from 'src/crypto/stringify-shuffle' import { firebase, pushover } from '../_services' @@ -34,9 +33,7 @@ export default async (req: NextApiRequest, res: NextApiResponse) => { // Fetch encrypted vote from database const votes = await electionDoc.collection('votes').where('auth', '==', auth_token).get() if (votes.empty) return res.status(404).json({ error: 'Vote not found' }) - const storedVote = votes.docs[0].data() - const storedEncryptedVote = storedVote.encrypted_vote as Record // Update the specific check entry const updatedChecks = data.checks.map((entry: { already_seen_device?: null | string; otp?: string }) => { @@ -56,7 +53,7 @@ export default async (req: NextApiRequest, res: NextApiResponse) => { return res.status(200).json({ encrypted_randomizers: checkEntry.encrypted_randomizers, - encrypted_vote: storedEncryptedVote, + encrypted_vote: storedVote.encrypted_vote, }) }