fix leverage display on account summary
This commit is contained in:
parent
75653c2ed4
commit
555f5625eb
|
@ -28,7 +28,9 @@ const MangoAccountSummary = () => {
|
|||
const totalCollateral = mangoAccount
|
||||
.getAssetsValue(group, HealthType.init)!
|
||||
.toNumber()
|
||||
return liabsValue / totalCollateral
|
||||
if (isNaN(liabsValue / totalCollateral)) {
|
||||
return 0
|
||||
} else return liabsValue / totalCollateral
|
||||
}, [mangoAccount])
|
||||
|
||||
return (
|
||||
|
|
Loading…
Reference in New Issue