From da6f163b433568e7a5db001f99e9cf5525d1d6a2 Mon Sep 17 00:00:00 2001 From: Luis Fernando Molina Date: Thu, 5 Dec 2019 17:21:37 +0100 Subject: [PATCH] Bug Fixed: 2 strategies running in paralell --- StatusReport.js | 16 +++------------- 1 file changed, 3 insertions(+), 13 deletions(-) diff --git a/StatusReport.js b/StatusReport.js index 239f382b7..76e30eace 100644 --- a/StatusReport.js +++ b/StatusReport.js @@ -97,7 +97,7 @@ /* Simplifying the access to basic info */ statusDependencyNode.bot = statusDependencyNode.referenceParent.parentNode.parentNode.code.codeName statusDependencyNode.process = statusDependencyNode.referenceParent.parentNode.code.codeName - statusDependencyNode.type = statusDependencyNode.referenceParent.parentNode.parentNode.type + statusDependencyNode.bottype = statusDependencyNode.referenceParent.parentNode.parentNode.type statusDependencyNode.devTeam = statusDependencyNode.referenceParent.parentNode.parentNode.parentNode.code.codeName /* Let's see if the process is run monthly or not. */ @@ -125,12 +125,10 @@ } statusDependencyNode.dataSetVersion = "dataSet.V1" - - - if (bot.SESSION !== undefined && statusDependencyNode.type === "Trading Bot Instance") { + if (bot.SESSION !== undefined && statusDependencyNode.bottype === "Trading Bot") { sessionPath = bot.SESSION.folderName + "/" } - + if (statusDependencyNode.processRunMonthly === true && month !== undefined && year !== undefined) { logger.fileName = MODULE_NAME + "." + statusDependencyNode.bot + "." + statusDependencyNode.process + "." + year + "." + month; timePath = "/" + year + "/" + month; @@ -163,10 +161,6 @@ filePath = bot.filePathRoot + "/Reports/" + sessionPath + statusDependencyNode.process + timePath; } - if (statusDependencyNode.type === 'Trading') { - fileName = bot.startMode + "." + fileName; - } - filePath += '/' + fileName fileStorage.getTextFile(statusDependencyNode.devTeam, filePath, onFileReceived); @@ -254,10 +248,6 @@ let fileName = "Status.Report." + global.MARKET.assetA + '_' + global.MARKET.assetB + ".json"; let filePath = bot.filePathRoot + "/Reports/" + sessionPath + statusDependencyNode.process + timePath; - if (bot.type === 'Trading' ) { - fileName = bot.startMode + "." + fileName; - } - filePath += '/' + fileName let fileContent = JSON.stringify(thisObject.file);