Skip to content

Commit

Permalink
fix: ekoke presale soft cap related to USDT raised
Browse files Browse the repository at this point in the history
  • Loading branch information
veeso committed Dec 5, 2024
1 parent d5c0e61 commit a8be27c
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 8 deletions.
2 changes: 1 addition & 1 deletion ethereum/app/src/js/components/App/pages/EkokePresale.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ const EkokePresale = () => {
});

client.softCap().then((value) => {
setSoftCap(convertToHumanReadable(value, 8, true));
setSoftCap(convertToHumanReadable(value, 6, true));
});
}, []);

Expand Down
2 changes: 1 addition & 1 deletion ethereum/app/src/js/web3/EkokePresaleClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ export default class EkokePresaleClient {

async softCap(): Promise<bigint> {
const contract = this.getContract();
return contract.methods.SOFT_CAP().call();
return contract.methods.SOFT_CAP_USDT().call();
}

async tokensSold(): Promise<bigint> {
Expand Down
25 changes: 19 additions & 6 deletions ethereum/app/src/js/web3/contracts/EkokePresale.ts
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ export const ABI = [
},
{
inputs: [],
name: 'SOFT_CAP',
name: 'SOFT_CAP_USDT',
outputs: [
{
internalType: 'uint256',
Expand Down Expand Up @@ -310,6 +310,19 @@ export const ABI = [
stateMutability: 'nonpayable',
type: 'function',
},
{
inputs: [],
name: 'usdt',
outputs: [
{
internalType: 'address',
name: '',
type: 'address',
},
],
stateMutability: 'view',
type: 'function',
},
{
inputs: [
{
Expand All @@ -318,7 +331,7 @@ export const ABI = [
type: 'address',
},
],
name: 'usdInvested',
name: 'usdtInvested',
outputs: [
{
internalType: 'uint256',
Expand All @@ -331,12 +344,12 @@ export const ABI = [
},
{
inputs: [],
name: 'usdt',
name: 'usdtRaised',
outputs: [
{
internalType: 'address',
internalType: 'uint256',
name: '',
type: 'address',
type: 'uint256',
},
],
stateMutability: 'view',
Expand All @@ -360,6 +373,6 @@ export const CONTRACT_ADDRESS: ContractAddress = {
[ChainId.Mainnet]: '',
[ChainId.Rinkeby]: '',
[ChainId.Ropsten]: '',
[ChainId.Sepolia]: '0x52127FB7507E987087D4aEfC42fbA60e372f8e97',
[ChainId.Sepolia]: '0x10B6bDB762aE3bAB9C6A097455252171b7F80457',
[ChainId.Hardhat]: '',
};

0 comments on commit a8be27c

Please sign in to comment.