mirror of
https://github.com/tornadocash/tornado-governance
synced 2024-02-02 14:53:55 +01:00
change visibility of (un)lock functions for simpler inheritance
This commit is contained in:
parent
280bbbad55
commit
6af010c5eb
@ -104,16 +104,16 @@ contract Governance is Initializable, Configuration, Delegation, EnsResolve {
|
||||
uint8 v,
|
||||
bytes32 r,
|
||||
bytes32 s
|
||||
) external virtual {
|
||||
) public virtual {
|
||||
torn.permit(owner, address(this), amount, deadline, v, r, s);
|
||||
_transferTokens(owner, amount);
|
||||
}
|
||||
|
||||
function lockWithApproval(uint256 amount) external virtual {
|
||||
function lockWithApproval(uint256 amount) public virtual {
|
||||
_transferTokens(msg.sender, amount);
|
||||
}
|
||||
|
||||
function unlock(uint256 amount) external virtual {
|
||||
function unlock(uint256 amount) public virtual {
|
||||
require(getBlockTimestamp() > canWithdrawAfter[msg.sender], "Governance: tokens are locked");
|
||||
lockedBalance[msg.sender] = lockedBalance[msg.sender].sub(amount, "Governance: insufficient balance");
|
||||
require(torn.transfer(msg.sender, amount), "TORN: transfer failed");
|
||||
|
Loading…
Reference in New Issue
Block a user