Bug correction negate needs to be set as false by default

This commit is contained in:
ybouane 2024-10-21 22:36:56 -04:00
parent 505a86366d
commit 91851ce3e9

View file

@ -14,7 +14,7 @@ const statusFile = './static/status.json';
const delay = async t=>new Promise(r=>setTimeout(r, t));
const handlize = s=>s.toLowerCase().replace(/[^a-z0-9]/g, ' ').trim().replace(/\s+/g, '-');
const checkContent = async (content, criterion, negate) => {
const checkContent = async (content, criterion, negate=false) => {
if(typeof criterion=='string') {
return content.includes(criterion)!=negate;
} else if(Array.isArray(criterion)) {