Skip to content

Commit

Permalink
fix: undefined headers to be zero instead
Browse files Browse the repository at this point in the history
  • Loading branch information
MrMysterius committed Aug 17, 2024
1 parent f93836b commit 3e6174f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/extract/write-csv.ts
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ export async function writeCSVFile(path: string, runs: z.infer<typeof VRunData>[
line += `${player.itemAcquisitionOrder.map((v) => v.item.display_name).join(" ")};`;

for (const header of headers.values()) {
line += `${player.statSheet.fields[header]};`;
line += `${player.statSheet.fields[header] || 0};`;
}

await writeToFile(File, line.replace(/\;$/, "\n"));
Expand Down

0 comments on commit 3e6174f

Please sign in to comment.