Skip to content

Commit

Permalink
[Fix] Increment CSV row count by 1 (#11965)
Browse files Browse the repository at this point in the history
* actually increment row by 1

* fix binary operation error

(cherry picked from commit 3886382)
  • Loading branch information
esizer authored and brindasasi committed Nov 14, 2024
1 parent 48263cb commit c97a178
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion api/app/Generators/PoolCandidateCsvGenerator.php
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ public function generate(): self
}

// 1 is added to the key to account for the header row
$sheet->fromArray($values, null, 'A'.$currentCandidate);
$sheet->fromArray($values, null, sprintf('A%d', $currentCandidate + 1));
$currentCandidate++;
}
});
Expand Down
2 changes: 1 addition & 1 deletion api/app/Generators/UserCsvGenerator.php
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ public function generate(): self
];

// 1 is added to the key to account for the header row
$sheet->fromArray($values, null, 'A'.$currentUser);
$sheet->fromArray($values, null, sprintf('A%d', $currentUser + 1));
$currentUser++;
}
});
Expand Down

0 comments on commit c97a178

Please sign in to comment.