Skip to content

Commit 7df4a91

Browse files
committed
misc: interfaces are missing functions present in their implementations
Some interfaces in the code base are not were matching their implementation, defining only a part of the functionalities implemented in their respective contracts.
1 parent fb97e82 commit 7df4a91

File tree

4 files changed

+38
-12
lines changed

4 files changed

+38
-12
lines changed

contracts/governance/Controller.sol

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,23 +64,23 @@ contract Controller is IController, Governed, Pausable {
6464
* @notice Change the partial paused state of the contract
6565
* Partial pause is intented as a partial pause of the protocol
6666
*/
67-
function setPartialPaused(bool _partialPaused) external onlyGovernorOrGuardian {
67+
function setPartialPaused(bool _partialPaused) external override onlyGovernorOrGuardian {
6868
_setPartialPaused(_partialPaused);
6969
}
7070

7171
/**
7272
* @notice Change the paused state of the contract
7373
* Full pause most of protocol functions
7474
*/
75-
function setPaused(bool _paused) external onlyGovernorOrGuardian {
75+
function setPaused(bool _paused) external override onlyGovernorOrGuardian {
7676
_setPaused(_paused);
7777
}
7878

7979
/**
8080
* @notice Change the Pause Guardian
8181
* @param _newPauseGuardian The address of the new Pause Guardian
8282
*/
83-
function setPauseGuardian(address _newPauseGuardian) external onlyGovernor {
83+
function setPauseGuardian(address _newPauseGuardian) external override onlyGovernor {
8484
_setPauseGuardian(_newPauseGuardian);
8585
}
8686

contracts/governance/IController.sol

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,23 @@ pragma solidity ^0.6.12;
33
interface IController {
44
event SetContractProxy(bytes32 id, address contractAddress);
55

6+
function getGovernor() external view returns (address);
7+
8+
// -- Registry --
9+
610
function setContractProxy(bytes32 _id, address _contractAddress) external;
711

812
function updateController(bytes32 _id, address _controller) external;
913

1014
function getContractProxy(bytes32 _id) external view returns (address);
1115

12-
function getGovernor() external view returns (address);
16+
// -- Pausing --
17+
18+
function setPartialPaused(bool _partialPaused) external;
19+
20+
function setPaused(bool _paused) external;
21+
22+
function setPauseGuardian(address _newPauseGuardian) external;
1323

1424
function paused() external view returns (bool);
1525

contracts/staking/Staking.sol

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -393,14 +393,6 @@ contract Staking is StakingV1Storage, GraphUpgradeable, IStaking {
393393
emit AssetHolderUpdate(msg.sender, _assetHolder, _allowed);
394394
}
395395

396-
/**
397-
* @dev Get the GRT token used by the contract.
398-
* @return GRT token contract address
399-
*/
400-
function token() public view returns (IGraphToken) {
401-
return graphToken();
402-
}
403-
404396
/**
405397
* @dev Return if allocationID is used.
406398
* @param _allocationID Address used as signer by the indexer for an allocation

contracts/token/IGraphToken.sol

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,31 @@ pragma solidity ^0.6.12;
33
import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
44

55
interface IGraphToken is IERC20 {
6+
// -- Mint and Burn --
7+
68
function burn(uint256 amount) external;
79

810
function mint(address _to, uint256 _amount) external;
11+
12+
// -- Mint Admin --
13+
14+
function addMinter(address _account) external;
15+
16+
function removeMinter(address _account) external;
17+
18+
function renounceMinter() external;
19+
20+
function isMinter(address _account) external view returns (bool);
21+
22+
// -- Permit --
23+
24+
function permit(
25+
address _owner,
26+
address _spender,
27+
uint256 _value,
28+
uint256 _deadline,
29+
uint8 _v,
30+
bytes32 _r,
31+
bytes32 _s
32+
) external;
933
}

0 commit comments

Comments
 (0)