Skip to content

Commit

Permalink
Remove redundant issueTokens method on NodeDriverAuth
Browse files Browse the repository at this point in the history
  • Loading branch information
Mike-CZ committed Nov 27, 2024
1 parent 57ecc32 commit e36a4cd
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 9 deletions.
8 changes: 0 additions & 8 deletions contracts/sfc/NodeDriverAuth.sol
Original file line number Diff line number Diff line change
Expand Up @@ -83,14 +83,6 @@ contract NodeDriverAuth is OwnableUpgradeable, UUPSUpgradeable {

/// Mint native token. To be used by SFC for minting validators rewards.
function incBalance(address acc, uint256 diff) external onlySFC {
if (acc != address(sfc)) {
revert RecipientNotSFC();
}
driver.setBalance(acc, address(acc).balance + diff);
}

/// Issue tokens as a counterparty to burnt FTM tokens.
function issueTokens(address acc, uint256 diff) external onlySFC {
driver.setBalance(acc, address(acc).balance + diff);
}

Expand Down
2 changes: 1 addition & 1 deletion contracts/sfc/SFC.sol
Original file line number Diff line number Diff line change
Expand Up @@ -464,7 +464,7 @@ contract SFC is OwnableUpgradeable, UUPSUpgradeable, Version {
if (c.issuedTokensRecipient() == address(0)) {
revert ZeroAddress();
}
node.issueTokens(c.issuedTokensRecipient(), amount);
node.incBalance(c.issuedTokensRecipient(), amount);
totalSupply += amount;
}

Expand Down

0 comments on commit e36a4cd

Please sign in to comment.