Handle SQLite date strings

Fixes #475, fixes #512
This commit is contained in:
rijkvanzanten
2020-10-05 18:39:31 -04:00
parent 57ec6eab7e
commit e40b9133cb

View File

@@ -246,7 +246,9 @@ export class PayloadService {
for (const dateColumn of dateColumns) {
for (const payload of payloads) {
const value: Date = payload[dateColumn.name];
let value: string | Date = payload[dateColumn.name];
if (typeof value === 'string') value = new Date(value);
if (value) {
if (dateColumn.type === 'timestamp') {