Update generated content

Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
This commit is contained in:
CrazyMax
2021-09-03 13:32:19 +02:00
parent 21bf2cd4f9
commit 36db8814f9

2
dist/index.js generated vendored
View File

@@ -2606,7 +2606,7 @@ class Parser extends Transform {
const date = Date.parse(value) const date = Date.parse(value)
return !isNaN(date) ? new Date(date) : value return !isNaN(date) ? new Date(date) : value
} }
}else if(typeof options.cast_date !== 'function'){ }else{
throw new CsvError('CSV_INVALID_OPTION_CAST_DATE', [ throw new CsvError('CSV_INVALID_OPTION_CAST_DATE', [
'Invalid option cast_date:', 'cast_date must be true or a function,', 'Invalid option cast_date:', 'cast_date must be true or a function,',
`got ${JSON.stringify(options.cast_date)}` `got ${JSON.stringify(options.cast_date)}`