feat: prettier and eslint

This commit is contained in:
GramingFoxTeam
2022-11-16 13:59:55 +03:00
parent 0ad5ece085
commit 1c27ccb17c
22 changed files with 2359 additions and 324 deletions

View File

@@ -2,22 +2,22 @@ import { recognize } from 'node-tesseract-ocr';
import { serialize } from 'bson';
export default async function runOCR(client, eventData) {
const config = {
lang: 'eng',
oem: 3,
psm: 3,
};
const config = {
lang: 'eng',
oem: 3,
psm: 3
};
const ocrText = await recognize(eventData.url, config);
const ocrText = await recognize(eventData.url, config);
const jsonData = {
op: 6,
id: eventData.id,
ocrText
};
const jsonData = {
op: 6,
id: eventData.id,
ocrText
};
const bsonData = serialize(jsonData);
client.write(bsonData);
const bsonData = serialize(jsonData);
client.write(bsonData);
return;
}
return;
}