Skip to content

Commit

Permalink
Make getters internal
Browse files Browse the repository at this point in the history
  • Loading branch information
geoff-vball committed Nov 29, 2024
1 parent e7103d2 commit 9144511
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 352 deletions.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions contracts/validator-manager/PoSValidatorManager.sol
Original file line number Diff line number Diff line change
Expand Up @@ -312,7 +312,7 @@ abstract contract PoSValidatorManager is
/**
* @notice Returns the settings for the validator manager contract
*/
function getSettings() external view returns (PoSValidatorManagerSettings memory) {
function _getPoSSettings() internal view returns (PoSValidatorManagerSettings memory) {
PoSValidatorManagerStorage storage $ = _getPoSValidatorManagerStorage();

return PoSValidatorManagerSettings({
Expand All @@ -332,8 +332,8 @@ abstract contract PoSValidatorManager is
* @notice Returns the validator info for the given validation ID.
* @param validationID ID of the validtor being queried.
*/
function getPoSValidatorInfo(bytes32 validationID)
external
function _getPoSValidatorInfo(bytes32 validationID)
internal
view
returns (PoSValidatorInfo memory)
{
Expand All @@ -343,7 +343,7 @@ abstract contract PoSValidatorManager is
/**
* @notice Returns the delegator info for the given delegation ID.
*/
function getDelegator(bytes32 delegationID) external view returns (Delegator memory) {
function _getDelegator(bytes32 delegationID) internal view returns (Delegator memory) {
return _getPoSValidatorManagerStorage()._delegatorStakes[delegationID];
}

Check warning

Code scanning / Slither

Dead-code Warning

PoSValidatorManager._getDelegator(bytes32) is never used and should be removed

Expand Down
2 changes: 1 addition & 1 deletion contracts/validator-manager/ValidatorManager.sol
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ abstract contract ValidatorManager is Initializable, ContextUpgradeable, IValida
/**
* @notice Returns the validator churn period information for this contract.
*/
function getValidatorChurnPeriod() external view returns (ValidatorChurnPeriod memory) {
function _getValidatorChurnPeriod() internal view returns (ValidatorChurnPeriod memory) {
return _getValidatorManagerStorage()._churnTracker;
}

Check warning

Code scanning / Slither

Dead-code Warning

ValidatorManager._getValidatorChurnPeriod() is never used and should be removed

Expand Down

0 comments on commit 9144511

Please sign in to comment.