From 2432af243ecbce19c71d482ae5bb915c352131c7 Mon Sep 17 00:00:00 2001 From: Luis Fernando Molina Date: Tue, 6 Mar 2018 17:38:47 +0100 Subject: [PATCH] Assitant fully reviewed --- .vs/AAMariam-Trading-Bot/v15/.suo | Bin 27648 -> 19456 bytes Trading-Process/This.Bot.js | 20 ++++++++++---------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/.vs/AAMariam-Trading-Bot/v15/.suo b/.vs/AAMariam-Trading-Bot/v15/.suo index f86e153bc12e4e38062dd9dcd124bb28e20a72f9..afdb8ea41dd030d9d613731ab26e21451e067f84 100644 GIT binary patch delta 243 zcmZp;!Pqc^ae{#?0}Kc-Ft7pHj6nSF|Ns9WVaCl9S@IbtCb&#u%3&>7**+_6b0O1h z=E*)x3akdlQ|N;t*k!pFEL8da?nB2P;2NFCUO6&Z-7v$!(s=v5JM4 z0chxdULYStPrfLwvblsegm?1^Aq&P$GA>L!fZCnmT|V#;BCu(H-OdUGMu zZDvNc$%;(!tQQ)1{D1;%L5#eNyg=0&Kn&FQe{!R^%H%KX3XF1-C$dOSHsJ7Jo1u*k~3}CZ~ z6-KbE0+Q_J5``YwMKVl_RG2n7DKiUx2g<>~1Rz6svx(~&woMu?jFXQr8*DDo3}EC@ z28yc#G2Dg&Ml6$mXa#VHAPH_R(GFqckV6*vqQfIN`Mgu_=3b|1Od#*T0nDZ>mdU4# elmz&8O6-`mCW-r4NyJ|M0^uLPFfv%=#RLH3gnZWk diff --git a/Trading-Process/This.Bot.js b/Trading-Process/This.Bot.js index 66522e6ce..1cb1ebd5f 100644 --- a/Trading-Process/This.Bot.js +++ b/Trading-Process/This.Bot.js @@ -39,7 +39,7 @@ } catch (err) { logger.write("[ERROR] initialize -> onDone -> err = " + err); - callBackFunction("Operation Failed."); + callBackFunction("Operation Failed"); } } @@ -66,18 +66,18 @@ switch (err) { case null: { - callBackFunction(true); + callBackFunction(null); } break; case 'Retry Later': { // Something bad happened, but if we retry in a while it might go through the next time. logger.write("[ERROR] start -> onDone -> Retry Later. Requesting Execution Retry."); - callBackFunction(true, nextIntervalLapse); + callBackFunction(err); return; } break; - case 'Operation Failed': { // This is an unexpected exception that we do not know how to handle. + case 'Retry Later': { // This is an unexpected exception that we do not know how to handle. logger.write("[ERROR] start -> onDone -> Operation Failed. Aborting the process."); - callBackFunction(false); + callBackFunction(err); return; } break; @@ -85,7 +85,7 @@ } catch (err) { logger.write("[ERROR] start -> onDone -> err = " + err); - callBack("Operation Failed."); + callBack("Operation Failed"); } } @@ -173,7 +173,7 @@ } } catch (err) { logger.write("[ERROR] start -> businessLogic -> err = " + err); - callBack("Operation Failed."); + callBack("Operation Failed"); } } @@ -187,7 +187,7 @@ } catch (err) { logger.write("[ERROR] start -> decideAboutBuyPosition -> err = " + err); - callBack("Operation Failed."); + callBack("Operation Failed"); } } @@ -257,13 +257,13 @@ } catch (err) { logger.write("[ERROR] start -> decideAboutSellPosition -> err = " + err); - callBack("Operation Failed."); + callBack("Operation Failed"); } } } catch (err) { logger.write("[ERROR] start -> err = " + err); - callBack("Operation Failed."); + callBack("Operation Failed"); } } };