This commit is contained in:
jane 2021-06-06 01:15:54 -04:00
parent 42d6c8e85f
commit ddd2f1dfaf

View file

@ -64,7 +64,11 @@ app.use("/updates", express.text());
function diff(current, checked) { function diff(current, checked) {
let lines_current = current.split('\n').map(l => l.trim()).filter(l => l != ""); let lines_current = current.split('\n').map(l => l.trim()).filter(l => l != "");
let lines_checked = checked.split('\n').map(l => l.trim()).filter(l => l != ""); let lines_checked = checked.split('\n').map(l => l.trim()).filter(l => l != "");
let filenames_checked = lines_checked.map(l => l.split(" ")[0]); let filenames_checked = lines_checked.map(l => {
let split = l.split(" ");
console.log(`filename map: ${split}`);
return split[0] || l;
});
console.log(lines_current, lines_checked); console.log(lines_current, lines_checked);
console.log(filenames_checked); console.log(filenames_checked);