Closed 0xChqrles closed 2 months ago
I
Am available kindly assign @0xChqrles
if i understand the issue description correctly,
we are going to add a lock function to escrow component that take an amount and lock duration in second, save it to storage and dispatch an event.
the save of the price and duration will be in form of map of KEY to TUPLE, i.e MAP<user, (amount, lock_duraton)>
am i correct here @0xChqrles
The
lock
function of the escrow should take as a parameter a minimum lock duration expressed in seconds.The verification of compliance with this duration will be implemented later in a hook.
This way, a user who locks an amount in USDC must wait for a certain period before being able to withdraw their funds if no one has agreed to the exchange. However, a user who provides proof of an off-chain transfer can withdraw the funds without waiting.