mirror of
git://holbrook.no/erc20-demurrage-token
synced 2024-11-21 15:56:46 +01:00
Alias writer, emit missing events
This commit is contained in:
parent
edc9b6587c
commit
4e6e5300f7
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -138,7 +138,7 @@ contract DemurrageTokenSingleNocap {
|
||||
|
||||
// ACL setup
|
||||
owner = msg.sender;
|
||||
minter[owner] = true;
|
||||
// minter[owner] = true;
|
||||
|
||||
// ERC20 setup
|
||||
name = _name;
|
||||
@ -228,6 +228,9 @@ contract DemurrageTokenSingleNocap {
|
||||
minter[_minter] = true;
|
||||
return true;
|
||||
}
|
||||
function addWriter(address _minter) public returns (bool) {
|
||||
return addMinter(_minter);
|
||||
}
|
||||
|
||||
// Given address will no longer be allowed to call the mintTo() function
|
||||
function removeMinter(address _minter) public returns (bool) {
|
||||
@ -236,6 +239,9 @@ contract DemurrageTokenSingleNocap {
|
||||
minter[_minter] = false;
|
||||
return true;
|
||||
}
|
||||
function deleteWriter(address _minter) public returns (bool) {
|
||||
return removeMinter(_minter);
|
||||
}
|
||||
|
||||
/// Implements ERC20
|
||||
function balanceOf(address _account) public view returns (uint256) {
|
||||
@ -299,7 +305,8 @@ contract DemurrageTokenSingleNocap {
|
||||
|
||||
require(applyExpiry() == 0);
|
||||
require(minter[msg.sender], 'ERR_ACCESS');
|
||||
changePeriod();
|
||||
|
||||
changePeriod();
|
||||
if (maxSupply > 0) {
|
||||
require(supply + _amount <= maxSupply);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user