Skip to content

Commit

Permalink
[Refac] refac the token burn func.[DONE]
Browse files Browse the repository at this point in the history
  • Loading branch information
0xsaurabhx0 committed Nov 29, 2024
1 parent f44a8af commit 5d3c32a
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions solidity/src/HSTK.sol
Original file line number Diff line number Diff line change
Expand Up @@ -129,16 +129,13 @@ contract HstkToken is ERC20, Pausable, BlackListed {

/**
* @dev Burns tokens
* @param account The address whose tokens will be burned
* @param value The amount of tokens to burn
* Requirements:
* - Can only be called by the admin
* - Contract must not be paused
* - `account` cannot be the zero address
* - Contract must not be fully paused
*/
function burn(address account, uint256 value) external allowedInActiveOrPartialPause onlyMultiSig {
_burn(account, value);
emit Burn(account, value);
function burn(uint256 value) external allowedInActiveOrPartialPause {
_burn(_msgSender(), value);
emit Burn(_msgSender(), value);
}

/**
Expand Down

0 comments on commit 5d3c32a

Please sign in to comment.