|
@@ -51,7 +51,7 @@ export const extractMaxVolume = (data) => {
|
|
|
*/
|
|
*/
|
|
|
export const extractMaxTradedVolume = (data) => {
|
|
export const extractMaxTradedVolume = (data) => {
|
|
|
let vols = data.map(d => {
|
|
let vols = data.map(d => {
|
|
|
- if (d.marketDepth) return +d.marketDepth.lastTradedQty;
|
|
|
|
|
|
|
+ if (d.marketDepth) return +d.marketDepth.lastBuyQty > +d.marketDepth.lastSellQty ? +d.marketDepth.lastBuyQty : +d.marketDepth.lastSellQty;
|
|
|
else return 0;
|
|
else return 0;
|
|
|
}).sort((a, b) => a - b);
|
|
}).sort((a, b) => a - b);
|
|
|
if (vols.length > 0) return vols[vols.length - 1];
|
|
if (vols.length > 0) return vols[vols.length - 1];
|