Skip to content

Commit

Permalink
Remove duplicated isReportValidatorValid function
Browse files Browse the repository at this point in the history
  • Loading branch information
varasev committed Mar 18, 2021
1 parent aaacae2 commit ec26d7d
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 8 deletions.
2 changes: 1 addition & 1 deletion contracts/Certifier.sol
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ contract Certifier is UpgradeableOwned, ICertifier {
if (_certified[_who]) {
return true;
}
return validatorSetContract.isReportValidatorValid(_who);
return validatorSetContract.isReportValidatorValid(_who, true);
}

/// @dev Returns a boolean flag indicating whether the specified address is allowed to use zero gas price
Expand Down
6 changes: 0 additions & 6 deletions contracts/ValidatorSetAuRa.sol
Original file line number Diff line number Diff line change
Expand Up @@ -666,12 +666,6 @@ contract ValidatorSetAuRa is UpgradeabilityAdmin, IValidatorSetAuRa {
return isValidatorById[idByMiningAddress[_miningAddress]];
}

/// @dev See the description of isReportValidatorValid(address,bool) below.
/// Used for backward compatibility with the Certifier contract.
function isReportValidatorValid(address _miningAddress) public view returns(bool) {
return isReportValidatorValid(_miningAddress, true);
}

/// @dev Returns a boolean flag indicating whether the specified validator (mining address)
/// is able to call the `reportMalicious` function or whether the specified validator (mining address)
/// can be reported as malicious. This function also allows a validator to call the `reportMalicious`
Expand Down
1 change: 0 additions & 1 deletion contracts/interfaces/IValidatorSetAuRa.sol
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ interface IValidatorSetAuRa {
function hasEverBeenMiningAddress(address) external view returns(uint256);
function idByMiningAddress(address) external view returns(uint256);
function idByStakingAddress(address) external view returns(uint256);
function isReportValidatorValid(address) external view returns(bool);
function isReportValidatorValid(address, bool) external view returns(bool);
function isValidator(address) external view returns(bool);
function isValidatorById(uint256) external view returns(bool);
Expand Down

0 comments on commit ec26d7d

Please sign in to comment.