mirror of
https://gitlab.com/MrFry/mrfrys-node-server
synced 2025-04-01 20:24:18 +02:00
Added some logs, ask test script encodes JSON uri component
This commit is contained in:
parent
1aa5c7eef4
commit
45962874fd
4 changed files with 9 additions and 2 deletions
|
@ -297,6 +297,7 @@ function searchQuestion(subj, question, questionData, subjName) {
|
|||
subj.Name,
|
||||
questionData
|
||||
)
|
||||
|
||||
if (percent.avg > minMatchAmmount) {
|
||||
result.push({
|
||||
q: currentQuestion,
|
||||
|
@ -405,6 +406,8 @@ function searchData(data, question, subjName, questionData) {
|
|||
})
|
||||
|
||||
worker.on('message', (result) => {
|
||||
logger.DebugLog(`Worker message arrived`, 'worker', 2)
|
||||
logger.DebugLog(result, 'worker', 3)
|
||||
logger.DebugLog(`Question result length: ${result.length}`, 'ask', 1)
|
||||
logger.DebugLog(result, 'ask', 2)
|
||||
|
||||
|
@ -453,6 +456,7 @@ function dataToString(data) {
|
|||
|
||||
// ------------------------------------------------------------------------
|
||||
if (!isMainThread) {
|
||||
logger.DebugLog(`Starting search worker ...`, 'worker', 1)
|
||||
const { data, subjName, question, questionData } = workerData
|
||||
let result = []
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue