From 513d2cb863136b5835469539a00d68a4c7d010e5 Mon Sep 17 00:00:00 2001 From: Joel Kronqvist Date: Tue, 25 Oct 2022 20:32:10 +0300 Subject: Changed null to undefined as it should was meant to be. TL; DR: a typo. --- dbparse.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'dbparse.js') diff --git a/dbparse.js b/dbparse.js index 0f029b4..a3065c3 100644 --- a/dbparse.js +++ b/dbparse.js @@ -145,7 +145,7 @@ async function writeShift(weekday, shiftId, shiftLine, courseLine, DB) `INSERT IGNORE INTO shifts VALUES (${weekday}, ${shiftId}, ?, ?, ?)`, [courseName1, teacher, className1] )); - if (courseName2 !== null) { + if (courseName2 !== undefined) { dbOperations.push(DB.execute( `INSERT IGNORE INTO shifts VALUES (${weekday}, ${shiftId}, ?, ?, ?)`, [courseName2, teacher, className2] -- cgit v1.2.3