Skip to main content
3 votes

Curve Voting Escrow Explanations

Just an update to Liron's answer, the whitepaper is now moved to https://github.com/curvefi/curve-dao-contracts/blob/master/doc/README.md
0xbe1's user avatar
  • 31
2 votes

How to build an escrow contract that accepts ERC20 tokens like usdt, usdc etc not only ether

Yes, it is possible to implement the ability to receive ERC20 tokens in an escrow contract. Here is an example of how this could be done: Import the ERC20 contract: import "https://github.com/...
Yakitori's user avatar
  • 787
1 vote
Accepted

Curve Voting Escrow Explanations

The Curve DAO whitepaper was very helpful for me for understanding the code, I really recommend starting with it: https://curve.fi/files/CurveDAO.pdf Specifically this part:
Liron Achdut's user avatar
1 vote

How to build an escrow contract that accepts ERC20 tokens like usdt, usdc etc not only ether

I am trying to implement a similar function. Try this. I am not sure if it'll work but give it a try. pragma solidity ^0.8.0; interface IERC20 { function transferFrom(address _from, address _to, ...
code-wolf-byte's user avatar
1 vote

how can i check hashcode and th amount

The first thing that you are doing in the transferto function is: balances[trx_hash] = amount; But then, you do this check: require(balances[trx_hash] == 0, "Unique hash conflict, hash is ...
Jeremy Then's user avatar
  • 4,649
1 vote

Escrow.sol: The called function should be payable if you send value and the value you send should be less than your current balance

Your MyEscrow smart contract have any issues, let me explain them: When you declare this statement MyToken token; like storage variable, you must instantiate it with the erc20's smart contact address ...
Antonio Carito's user avatar

Only top scored, non community-wiki answers of a minimum length are eligible