Account Facet
Changes:
Added InternalTransfer
Method
InternalTransfer
MethodThis method allows a user to send their deposits to another userâs allocated balance. The receiver address cannot be a partyB and must not be in a liquidated state. This enables users to transfer funds between accounts without waiting for deallocateCooldown
. internalTransfer()
uses the balance of the sender's account, not allocatedBalance, so you'll have to call deallocate()
first if funds are already allocated.
Symmio can pause internal transfers when needed.
deallocate()
deallocate()
Before:
After:
Explanation: Added a new condition to enforce a debounce time between deallocation requests to prevent too frequent deallocations.
Summary of Changes
Added a debounce time check to the
deallocate
function to ensure that deallocation requests are not made too frequently. This is done by checking that the current block timestamp is greater than or equal to the sum of the user'swithdrawCooldown
and the globaldeallocateDebounceTime
.Maintained the existing check to ensure the user has sufficient allocated balance for the deallocation request.
This change helps to prevent abuse of the deallocation process by enforcing a time window between consecutive deallocations.
Last updated