aboutsummaryrefslogtreecommitdiff
path: root/parseExceptions.js
diff options
context:
space:
mode:
authorJoel Kronqvist <joelkronqvist@proton.me>2023-06-21 16:47:34 +0000
committerJoel Kronqvist <joelkronqvist@proton.me>2023-06-21 16:47:34 +0000
commite4bd0977da3621a8d3f82cab949a6734b169b71e (patch)
tree92f8079047b5d6bc951cb1eee02c3d2ceca339f3 /parseExceptions.js
parentc6eb85c138c267db08103de28a3a7c6dffee6c4f (diff)
downloadLYLLRuoka-e4bd0977da3621a8d3f82cab949a6734b169b71e.tar.gz
LYLLRuoka-e4bd0977da3621a8d3f82cab949a6734b169b71e.zip
Exception updation & minor polishing (but it's still WIP)
Diffstat (limited to 'parseExceptions.js')
-rw-r--r--parseExceptions.js7
1 files changed, 4 insertions, 3 deletions
diff --git a/parseExceptions.js b/parseExceptions.js
index 63cd6d2..42a1c50 100644
--- a/parseExceptions.js
+++ b/parseExceptions.js
@@ -50,9 +50,10 @@ assert.deepEqual(
async function updateExceptions(exceptions, DB) {
await DB.query_raw('DELETE FROM exceptions');
let dbOperations = [];
- for (line of exceptions.split('\n')) {
- if (line === '' || line[0] === '#')
- continue
+ for (let line of exceptions.split('\n')) {
+ if ((line === '') || (line === '\r') || (line[0] === '#')) {
+ continue;
+ }
const [start, end, header, message] = parseLine(line);
dbOperations.push(DB.execute(
'INSERT INTO exceptions VALUE (?, ?, ?, ?)',