Function: unlock(address token, uint256 amount)
This function unlocks a token.
Inputs
tokenControl: Fully controlled by the caller.
Constraints: None.
Impact: Specifies the token to be unlocked.
amountControl: Fully controlled by the caller.
Constraints: Must be less than the locked amount of the user.
Impact: Specifies the amount of tokens to be unlocked.
Branches and code coverage
Intended branches
Decrease the locked amount of the user.
Increase the cooldown amount of the user.
Update the cooldown period of the user.
Negative behavior
Contract is not paused.
Caller has enough locked amount to unlock.