Function: finishFrozenBalance(byte[32] _tokenHash, uint256 _chainId, uint128 _deltaBalance)
The function is triggered only from the accountWithDrawFinish
function of the Ledger contrast when the cross-chain process of withdrawal will be finished successfully.
Inputs
_tokenHash
Control: Actually controlled by operator, because the Vault contract in
chainId
just sends back cross-chain messages with received data.Constraints: If
tokenFrozenBalanceOnchain[_tokenHash][_chainId]
is less than_deltaBalance
, the call will revert.Impact: The frozen balance for
_tokenHash
in_chainId
will be decreased by_deltaBalance
amount.
_chainId
Control: Actually controlled by operator, because the Vault contract in
chainId
just sends back cross-chain messages with received data.Constraints: If
tokenFrozenBalanceOnchain[_tokenHash][_chainId]
is less than_deltaBalance
, the call will revert.Impact: The frozen balance for
_tokenHash
in_chainId
will be decreased by_deltaBalance
amount.
_deltaBalance
Control: Actually controlled by operator, because the Vault contract in
chainId
just sends back cross-chain messages with received data.Constraints: If
tokenFrozenBalanceOnchain[_tokenHash][_chainId]
is less than_deltaBalance
, the call will revert.Impact: The frozen balance for
_tokenHash
in_chainId
will be decreased by_deltaBalance
amount.
Branches and code coverage
Intended branches
The frozen balance was decreased properly.
Negative behavior
tokenFrozenBalanceOnchain[_tokenHash][_chainId]
is less than_deltaBalance
.The caller is not a trusted Ledger contract.