This commit is contained in:
Mel O'Hagan 2022-05-04 13:33:58 +01:00
parent 41b72027c4
commit d1e6e7549a
1 changed files with 1 additions and 2 deletions

View File

@ -48,8 +48,7 @@
$: { $: {
for (let i = 0; i < data.length; i++) { for (let i = 0; i < data.length; i++) {
let row = data[i] let row = data[i]
for (let fieldNameIndex in Object.keys(fields)) { for (let fieldName of Object.keys(fields)) {
let fieldName = Object.keys(fields)[fieldNameIndex]
if (fields[fieldName] === "number" && !isNaN(Number(row[fieldName]))) { if (fields[fieldName] === "number" && !isNaN(Number(row[fieldName]))) {
row[fieldName] = Number(row[fieldName]) row[fieldName] = Number(row[fieldName])
} else { } else {