Skip to content

Commit

Permalink
Merge pull request #19 from mountainprotocol/fix/N-06
Browse files Browse the repository at this point in the history
N-06 Fix
  • Loading branch information
mattiascaricato committed Jun 23, 2023
2 parents 500a2c9 + 2ba2e0b commit de984d1
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion contracts/USDM.sol
Expand Up @@ -20,31 +20,42 @@ contract USDM is
{
using CountersUpgradeable for CountersUpgradeable.Counter;

// Token name
string private _name;
// Token Symbol
string private _symbol;
// Total token shares
uint256 private _totalShares;
// Base value for rewardMultiplier
uint256 private constant _BASE = 1e18;
/**
* @dev rewardMultiplier represents a coefficient used in reward calculation logic.
* The value is represented with 18 decimal places for precision.
*/
uint256 public rewardMultiplier;

// Mapping of shares per address
mapping(address => uint256) private _shares;
// Mapping of block status per address
mapping(address => bool) private _blocklist;
// Mapping of allowances per owner and spender
mapping(address => mapping(address => uint256)) private _allowances;
// Mapping of nonces per address
mapping(address => CountersUpgradeable.Counter) private _nonces;

// Permit typehash constant
bytes32 private constant _PERMIT_TYPEHASH =
keccak256("Permit(address owner,address spender,uint256 value,uint256 nonce,uint256 deadline)");

// Access control roles
bytes32 public constant MINTER_ROLE = keccak256("MINTER_ROLE");
bytes32 public constant BURNER_ROLE = keccak256("BURNER_ROLE");
bytes32 public constant BLOCKLIST_ROLE = keccak256("BLOCKLIST_ROLE");
bytes32 public constant ORACLE_ROLE = keccak256("ORACLE_ROLE");
bytes32 public constant UPGRADE_ROLE = keccak256("UPGRADE_ROLE");
bytes32 public constant PAUSE_ROLE = keccak256("PAUSE_ROLE");

// Events
event AccountBlocked(address indexed addr);
event AccountUnblocked(address indexed addr);
event RewardMultiplier(uint256 indexed value);
Expand Down Expand Up @@ -639,5 +650,5 @@ contract USDM is
* variables without shifting down storage in the inheritance chain.
* See https://docs.openzeppelin.com/contracts/4.x/upgradeable#storage_gaps
*/
uint256[50] private __gap;
uint256[42] private __gap;
}

0 comments on commit de984d1

Please sign in to comment.