aboutsummaryrefslogtreecommitdiff
path: root/dbparse.js
diff options
context:
space:
mode:
authorJoel Kronqvist <work.joelkronqvist@gmail.com>2022-10-15 20:05:32 +0300
committerJoel Kronqvist <work.joelkronqvist@gmail.com>2022-10-15 20:05:32 +0300
commitb2925ef2579050c484a552f2cd9c0ffed11fb1e9 (patch)
treecf7708162afe815ef855e8af5e9a1012d2587ff6 /dbparse.js
parent98a7a9947828514372d873b88fcdcdf44a358dd3 (diff)
downloadLYLLRuoka-b2925ef2579050c484a552f2cd9c0ffed11fb1e9.tar.gz
LYLLRuoka-b2925ef2579050c484a552f2cd9c0ffed11fb1e9.zip
Bug fixes & started setup.sh
Diffstat (limited to 'dbparse.js')
-rw-r--r--dbparse.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/dbparse.js b/dbparse.js
index dde0ff5..29b9cb7 100644
--- a/dbparse.js
+++ b/dbparse.js
@@ -129,7 +129,7 @@ async function writeShift(weekday, shiftId, shiftLine, courseLine, DB)
className = null;
dbOperations.push(DB.execute(
- `INSERT INTO shifts VALUES (${weekday}, ${shiftId}, ?, ?, ?)`,
+ `INSERT IGNORE INTO shifts VALUES (${weekday}, ${shiftId}, ?, ?, ?)`,
[courseName, teacherName, className]
));
}
@@ -195,4 +195,4 @@ exports.build = writeShifts;
exports.get = getShift;
exports.randomIndex = getRandomIndex;
exports.find = findExpression;
-exports.getNextChar = getNextChar; \ No newline at end of file
+exports.getNextChar = getNextChar;