From 577170935a200ca14a03ac4ea6ea4841a699e667 Mon Sep 17 00:00:00 2001 From: Mattk70 Date: Sun, 5 Nov 2023 20:24:51 +0000 Subject: [PATCH] fixed merge errors --- js/worker.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/js/worker.js b/js/worker.js index 972cfad1..c9721549 100644 --- a/js/worker.js +++ b/js/worker.js @@ -69,7 +69,7 @@ const createDB = async (file) => { await db.runAsync(`CREATE TABLE records( dateTime INTEGER, position INTEGER, fileID INTEGER, speciesID INTEGER, confidence INTEGER, label TEXT, - comment TEXT, end INTEGER, callCount INTEGER, isDaylight INTEGER, isDaylight INTEGER, + comment TEXT, end INTEGER, callCount INTEGER, isDaylight INTEGER, UNIQUE (dateTime, fileID, speciesID), CONSTRAINT fk_files FOREIGN KEY (fileID) REFERENCES files(id) ON DELETE CASCADE, @@ -1595,8 +1595,9 @@ const terminateWorkers = () => { predictWorkers = []; } -const insertRecord = async (timestamp, timestamp, key, speciesID, confidence, file) => { +const insertRecord = async (timestamp, key, speciesID, confidence, file) => { const isDaylight = isDuringDaylight(timestamp, STATE.lat, STATE.lon); + const offset = key * 1000; let changes, fileID; confidence = Math.round(confidence); const db = memoryDB; //STATE.db;