Skip to content

Commit

Permalink
Patch checker logic
Browse files Browse the repository at this point in the history
  • Loading branch information
svemat01 committed Nov 15, 2024
1 parent 96ce02e commit aaffdbb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions backend/src/checker.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { and, eq } from "drizzle-orm";
import { and, eq, isNull, or } from "drizzle-orm";
import { db } from "./db";
import { links, links as linksTable } from "./db/schema";
import { batcher } from "./util/batch";
Expand Down Expand Up @@ -36,7 +36,7 @@ export const checkClaims = async (
emit("Checking POAP claims");

const usedLinks = await db.query.links.findMany({
where: eq(linksTable.claimed, false),
where: or(eq(linksTable.claimed, false), isNull(linksTable.claimed)),
});

const batches = batcher(usedLinks, 10);
Expand Down

0 comments on commit aaffdbb

Please sign in to comment.