diff --git a/main.cjs b/main.cjs index 0fa9ae8..b491939 100644 --- a/main.cjs +++ b/main.cjs @@ -210,13 +210,13 @@ function getMatchingPhrase(inputString, targetCharacter) { console.log(message.attachments); message.attachments.forEach(i => { if (i.contentType.includes("image")) { - (async () => { - const worker = await createWorker('eng'); - const ret = await worker.recognize(i.proxyURL); - console.log("OCR Results: " + ret.data.text); - checkString = ret.data.text; - await worker.terminate(); - })(); + //(async () => { + const worker = createWorker('eng'); + const ret = worker.recognize(i.proxyURL); + console.log("OCR Results: " + ret.data.text); + checkString = ret.data.text; + worker.terminate(); + //})(); console.log("Checking OCR contents..."); if (checkLoop(message, checkString)) { return;