🐛 Handle bit (boolean) values correctly when inserting (#1949)

This commit is contained in:
Ricardo Espinoza 2021-06-29 04:40:47 -04:00 committed by GitHub
parent 29eab1dbcd
commit b2e2cfa773
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -102,6 +102,8 @@ export function extractValues(item: IDataObject): string {
return 'NULL';
} else if (typeof val === 'string') {
return `'${val.replace(/'/g, '\'\'')}'`;
} else if (typeof val === 'boolean') {
return +!!val;
}
return val;
}) // maybe other types such as dates have to be handled as well