Skip to content

Commit

Permalink
bonding: remove duplicate IBondingManager interface
Browse files Browse the repository at this point in the history
  • Loading branch information
red-0ne committed May 25, 2022
1 parent d617844 commit 58c1e20
Show file tree
Hide file tree
Showing 7 changed files with 8 additions and 11 deletions.
2 changes: 1 addition & 1 deletion contracts/bonding/BondingManager.sol
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
pragma solidity 0.8.9;

import "../ManagerProxyTarget.sol";
import "./IBondingManager.sol";
import "../interfaces/IBondingManager.sol";
import "../libraries/SortedDoublyLL.sol";
import "../libraries/MathUtils.sol";
import "../libraries/PreciseMathUtils.sol";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,4 +78,6 @@ interface IBondingManager {
function isActiveTranscoder(address _transcoder) external view returns (bool);

function getTotalBonded() external view returns (uint256);

function pendingStake(address _addr, uint256 _endRound) external view returns (uint256);
}
2 changes: 1 addition & 1 deletion contracts/pm/mixins/interfaces/MContractRegistry.sol
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// SPDX-License-Identifier: MIT
pragma solidity 0.8.9;

import "../../../bonding/IBondingManager.sol";
import "../../../interfaces/IBondingManager.sol";
import "../../../token/IMinter.sol";
import "../../../rounds/IRoundsManager.sol";

Expand Down
7 changes: 1 addition & 6 deletions contracts/polling/PollCreator.sol
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,7 @@
pragma solidity 0.8.9;

import "./Poll.sol";

interface IBondingManager {
function transcoderTotalStake(address _addr) external view returns (uint256);

function pendingStake(address _addr, uint256 _endRound) external view returns (uint256);
}
import "../interfaces/IBondingManager.sol";

contract PollCreator {
// 33.33%
Expand Down
2 changes: 1 addition & 1 deletion contracts/rounds/RoundsManager.sol
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ pragma solidity 0.8.9;

import "../ManagerProxyTarget.sol";
import "./IRoundsManager.sol";
import "../bonding/IBondingManager.sol";
import "../interfaces/IBondingManager.sol";
import "../token/IMinter.sol";
import "../libraries/MathUtils.sol";

Expand Down
2 changes: 1 addition & 1 deletion contracts/token/Minter.sol
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import "../Manager.sol";
import "./IMinter.sol";
import "./ILivepeerToken.sol";
import "../rounds/IRoundsManager.sol";
import "../bonding/IBondingManager.sol";
import "../interfaces/IBondingManager.sol";
import "../libraries/MathUtilsV2.sol";

import "@openzeppelin/contracts/utils/math/SafeMath.sol";
Expand Down
2 changes: 1 addition & 1 deletion test/unit/PollCreator.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ describe("PollCreator", () => {
fixture = new Fixture(web3)

bondingManagerMock = await smock.fake(
"contracts/polling/PollCreator.sol:IBondingManager",
"contracts/interfaces/IBondingManager.sol:IBondingManager",
{
address: mockBondingManagerEOA.address
}
Expand Down

0 comments on commit 58c1e20

Please sign in to comment.