diff --git a/src/execution.ts b/src/execution.ts index e55e9b5..c66ad4f 100644 --- a/src/execution.ts +++ b/src/execution.ts @@ -28,13 +28,11 @@ export function getAuthor(request: apiRequest) { * @param requestTimestamp the timestamp of the user request * @returns object containing the limit and remaining usage or `false` if there is no limit */ -async function getUserLimit(user: string | {id: string}, requestTimestamp: Date) { +export async function getUserLimit(user: string | { id: string }, requestTimestamp: Date) { const userId: string = typeof user === "string" ? user : user.id; const userLimits = await database.limits.findUnique({ - where: { - user: BigInt(userId) - } + where: { user: BigInt(userId) } }); if (userLimits?.vip) return false;