chore(root): migrate to biome

This commit is contained in:
Carl-Gerhard Lindesvärd
2024-09-16 12:20:40 +02:00
parent 1f6e198336
commit 32e91959f6
383 changed files with 1943 additions and 3085 deletions

View File

@@ -128,7 +128,7 @@ export async function incomingEvent(job: Job<EventsQueuePayloadIncomingEvent>) {
{
delay: SESSION_END_TIMEOUT,
jobId: sessionEndJobId,
}
},
);
}
@@ -178,7 +178,7 @@ export async function incomingEvent(job: Job<EventsQueuePayloadIncomingEvent>) {
function getSessionEndWithPriority(
priority: boolean,
count = 0
count = 0,
): typeof getSessionEnd {
return async (args) => {
const res = await getSessionEnd(args);
@@ -208,13 +208,13 @@ async function getSessionEnd({
previousDeviceId: string;
}) {
const sessionEndKeys = await getRedisQueue().keys(
`*:sessionEnd:${projectId}:*`
`*:sessionEnd:${projectId}:*`,
);
const sessionEndJobCurrentDeviceId = await findJobByPrefix(
sessionsQueue,
sessionEndKeys,
`sessionEnd:${projectId}:${currentDeviceId}:`
`sessionEnd:${projectId}:${currentDeviceId}:`,
);
if (sessionEndJobCurrentDeviceId) {
return { deviceId: currentDeviceId, job: sessionEndJobCurrentDeviceId };
@@ -223,7 +223,7 @@ async function getSessionEnd({
const sessionEndJobPreviousDeviceId = await findJobByPrefix(
sessionsQueue,
sessionEndKeys,
`sessionEnd:${projectId}:${previousDeviceId}:`
`sessionEnd:${projectId}:${previousDeviceId}:`,
);
if (sessionEndJobPreviousDeviceId) {
return { deviceId: previousDeviceId, job: sessionEndJobPreviousDeviceId };