Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion scripts/update-topgear-reviewers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ const SCRIPT_ACTOR = 'scripts/update-topgear-reviewers';

interface ChallengePhaseInfo {
id: string;
phaseId: string;
name: string;
}

Expand Down Expand Up @@ -151,6 +152,7 @@ async function backfillChallengeReviewers() {
phases: {
select: {
id: true,
phaseId: true,
name: true,
},
},
Expand Down Expand Up @@ -237,7 +239,7 @@ async function backfillChallengeReviewers() {
for (const phase of matchingPhases) {
records.push({
challengeId: challenge.id,
phaseId: phase.id,
phaseId: phase.phaseId,
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[❗❗ correctness]
The change from phase.id to phase.phaseId assumes that phase.phaseId is always correctly populated and distinct from phase.id. Ensure that phase.phaseId is indeed the correct identifier for the intended operation and that it does not introduce any logical errors or inconsistencies, especially if phase.id was previously used as the primary identifier.

scorecardId: defaultReviewer.scorecardId,
isMemberReview: defaultReviewer.isMemberReview,
memberReviewerCount: defaultReviewer.isMemberReview
Expand Down