mirror of
https://gitlab.com/MrFry/mrfrys-node-server
synced 2026-04-28 03:07:38 +02:00
p2p submodule split, bug fixes
This commit is contained in:
@@ -6,8 +6,11 @@ import { RecievedData } from '../../utils/actions'
|
||||
import { removeCacheFromQuestion } from '../../utils/qdbUtils'
|
||||
import { QuestionAddResponse } from '../../modules/api/submodules/qminingapi'
|
||||
import logger from '../../utils/logger'
|
||||
import { peerToString, loginAndPostDataToAllPeers } from '../../utils/p2putils'
|
||||
import { post } from '../../utils/networkUtils'
|
||||
import {
|
||||
loginAndPostDataToAllPeers,
|
||||
peerToString,
|
||||
} from '../../modules/api/p2p/p2putils'
|
||||
|
||||
export type QuestionsToPeersTaskObject = {
|
||||
type: 'sendQuestionsToPeers'
|
||||
@@ -74,7 +77,11 @@ export const handleQuestionsToPeers = async (
|
||||
}
|
||||
}
|
||||
)
|
||||
logger.Log(`Peers that added new questions: ${hadNewQuestions.join(', ')}`)
|
||||
if (hadNewQuestions.length > 0) {
|
||||
logger.Log(
|
||||
`\t Peers that added new questions: ${hadNewQuestions.join(', ')}`
|
||||
)
|
||||
}
|
||||
|
||||
parentPort.postMessage({
|
||||
msg: `From thread #${workerIndex}: sendQuestionsToPeers done`,
|
||||
|
||||
Reference in New Issue
Block a user