refactor: status code register csv
This commit is contained in:
parent
8533c8e090
commit
f3c0ffb870
|
|
@ -821,6 +821,15 @@ export const registerStudentCSV = async (req, res) => {
|
||||||
|
|
||||||
await transaction.commit();
|
await transaction.commit();
|
||||||
|
|
||||||
|
if (processed.length === 0) {
|
||||||
|
return response(
|
||||||
|
400,
|
||||||
|
null,
|
||||||
|
"No students were registered. All entries are duplicates.",
|
||||||
|
res
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
response(
|
response(
|
||||||
200,
|
200,
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user