File tree Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -111,6 +111,15 @@ async function fetchDefaultReviewers(
111111
112112async function backfillChallengeReviewers() {
113113 const defaultsCache = new Map<string, DefaultChallengeReviewer[]>();
114+
115+ const taskTypes = await prisma.challengeType.findMany({
116+ where: {
117+ name: { equals: 'Task', mode: 'insensitive' },
118+ },
119+ select: { id: true },
120+ });
121+ const taskTypeIds = new Set(taskTypes.map((type) => type.id));
122+
114123 const challenges = await prisma.challenge.findMany({
115124 where: {
116125 status: ChallengeStatusEnum.ACTIVE,
@@ -148,6 +157,13 @@ async function backfillChallengeReviewers() {
148157 continue;
149158 }
150159
160+ if (taskTypeIds.has(challenge.typeId)) {
161+ console.log(
162+ `Skipping challenge ${challenge.id} (${challenge.name}) because it is a Task type.`,
163+ );
164+ continue;
165+ }
166+
151167 const defaultReviewers = await fetchDefaultReviewers(
152168 challenge.typeId,
153169 challenge.trackId,
You can’t perform that action at this time.
0 commit comments