Skip to content

Commit 3274fed

Browse files
authored
Merge pull request #286 from alchemix-finance/staging
HOTFIX: Staging
2 parents 4ed1638 + 0a5949e commit 3274fed

File tree

1 file changed

+12
-9
lines changed

1 file changed

+12
-9
lines changed

src/components/vaults/row/Migrate.tsx

+12-9
Original file line numberDiff line numberDiff line change
@@ -67,15 +67,18 @@ export const Migrate = ({
6767
writeMigrate();
6868
};
6969

70-
const ltv = toString(
71-
multiply(
72-
divide(
73-
[vault.alchemist.position.debt, 18],
74-
[vault.alchemist.totalValue, 18],
75-
),
76-
100,
77-
),
78-
);
70+
const ltv =
71+
vault.alchemist.totalValue > 0
72+
? toString(
73+
multiply(
74+
divide(
75+
[vault.alchemist.position.debt, 18],
76+
[vault.alchemist.totalValue, 18],
77+
),
78+
100,
79+
),
80+
)
81+
: "0";
7982

8083
return (
8184
<div className="space-y-4">

0 commit comments

Comments
 (0)