Closed bacca87 closed 6 years ago
Hi, the spreadPercent calculation in your code is wrong. To get the right value you should divide by the sell price instead of the buy price.
Original code: let spreadPercent = (spreadPrice / buyPrice) * 100;
let spreadPercent = (spreadPrice / buyPrice) * 100;
Fix: let spreadPercent = (spreadPrice / sellPrice) * 100;
let spreadPercent = (spreadPrice / sellPrice) * 100;
Thank @bacca87 , i will fix it soon
Hi, the spreadPercent calculation in your code is wrong. To get the right value you should divide by the sell price instead of the buy price.
Original code:
let spreadPercent = (spreadPrice / buyPrice) * 100;
Fix:
let spreadPercent = (spreadPrice / sellPrice) * 100;