Bug Fixed Issue #318. Using # in the name of the trading system didn't show backtest results.

This commit is contained in:
Luis Fernando Molina committed 2021-01-21 20:14:57 +01:00
1 parent e80592530f
commit 3ea470bf60
4 files changed
+13 -5

No files matched your search

+5 -2
View File
@@ -2,7 +2,7 @@ function newFileStorage(host, port) {
const MODULE_NAME = 'File Storage'
const INFO_LOG = false
const logger = newWebDebugLog()
const MAX_RETRY = 2
let currentRetry = 0
@@ -37,13 +37,16 @@ function newFileStorage(host, port) {
if (pathComplete === false || pathComplete === undefined) {
folder = 'Storage/'
}
let url = folder + filePath
let url
if (host !== undefined && port !== undefined) {
url = 'http://' + host + ':' + port + '/' + folder + filePath
} else {
url = folder + filePath
}
/* Scaping # since it breaks the URL */
url = url.replaceAll('#', 'HASHTAG')
httpRequest(undefined, url, (response, fileContent) => {
if (response.result === GLOBAL.DEFAULT_OK_RESPONSE.result) {
callBackFunction(GLOBAL.DEFAULT_OK_RESPONSE, fileContent)