Skip to content

Commit 3c88a8f

Browse files
committed
fxdao: bugfix
1 parent 84ca9e3 commit 3c88a8f

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

projects/fxdao/api.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
const { SorobanRpc, Networks, Address, xdr, Asset, scValToNative } = require('@stellar/stellar-sdk');
1+
const { rpc, Networks, Address, xdr, Asset, scValToNative } = require('@stellar/stellar-sdk');
22

33
const VAULTS_CONTRACT_ID = "CCUN4RXU5VNDHSF4S4RKV4ZJYMX2YWKOH6L4AKEKVNVDQ7HY5QIAO4UB";
44
const rpcUrl = 'https://soroban-rpc.creit.tech/';
5-
const server = new SorobanRpc.Server(rpcUrl);
5+
const server = new rpc.Server(rpcUrl);
66

77
async function tvl(api) {
88
const response = await server.getContractData(
@@ -11,7 +11,7 @@ async function tvl(api) {
1111
xdr.ScVal.scvSymbol('Balance'),
1212
new Address(VAULTS_CONTRACT_ID).toScVal(),
1313
]),
14-
SorobanRpc.Durability.Persistent
14+
rpc.Durability.Persistent
1515
);
1616
const balance = scValToNative(response.val.value().val()).amount;
1717
const parsedBalance = Number(balance) / 1e7;

0 commit comments

Comments
 (0)