Logs and Error Handling improvements

This commit is contained in:
Luis Fernando Molina committed 2018-05-30 09:29:14 +02:00
1 parent 38fe8dfa2b
commit 0ef1dcd891
5 files changed
+61 -32

No files matched your search

+2 -2
View File
@@ -401,7 +401,7 @@
analizeResponse: function (logger, exchangeErr, exchangeResponse, notOkCallBack, okCallBack) {
const FULL_LOG = false;
const INFO_LOG = false;
const LOG_FILE_CONTENT = false;
/* This function analizes the different situations we might encounter trying to access Poloniex and returns appropiate standard errors. */
@@ -411,7 +411,7 @@
let stringExchangeResponse = JSON.stringify(exchangeResponse);
let stringExchangeErr = JSON.stringify(exchangeErr);
if (FULL_LOG === true) { logger.write("[INFO] analizeResponse -> exchangeErr = " + stringExchangeErr); }
if (INFO_LOG === true) { logger.write("[INFO] analizeResponse -> exchangeErr = " + stringExchangeErr); }
if (LOG_FILE_CONTENT === true) { logger.write("[INFO] analizeResponse -> exchangeResponse = " + stringExchangeResponse); }
if (stringExchangeErr.indexOf("ETIMEDOUT") > 0 ||