diff --git a/dabo/functions/check_sell_conditions.sh b/dabo/functions/check_sell_conditions.sh index 616d43b..90d3a51 100644 --- a/dabo/functions/check_sell_conditions.sh +++ b/dabo/functions/check_sell_conditions.sh @@ -33,9 +33,10 @@ function check_sell_conditions { fi # result values (sould be reduced to one - f_result!?) - f_BUY_PRICE_LAST_RATE_DIFF=$(g_percentage-diff ${f_BUY_PRICE} ${f_price}) + f_result=$(g_percentage-diff ${f_BUY_PRICE} ${f_price}) + f_BUY_PRICE_LAST_RATE_DIFF=${f_result} result=${f_BUY_PRICE_LAST_RATE_DIFF} - f_result=${f_BUY_PRICE_LAST_RATE_DIFF} + f_real_result=$(echo "${f_result-$FEE}" | bc) # store new interim result echo ${f_BUY_PRICE_LAST_RATE_DIFF} >>${f_TRADE_HIST_FILE_INTERIM}