shystruk/csv-file-validator

Number of fields check for the first row

mzbortek opened this issue · 0 comments

I think this check needs to be done also for the first row of CSV file.

So, instead of this:

			// fields are mismatch
			if (rowIndex !== 0 && row.length !== config.headers.length) {

should be this:

			// fields are mismatch
			if (row.length !== config.headers.length) {