Remove abbreviations from parameters (#1142)
* Add an initial document for our code style * Remove abbreviations from parameters * Rename the param in AddressUtils * fix comment
This commit is contained in:
committed by
Nicolás Venturo
parent
7fdca7b025
commit
f49721576f
@ -4,33 +4,33 @@ import "../access/SignatureBouncer.sol";
|
||||
|
||||
|
||||
contract SignatureBouncerMock is SignatureBouncer {
|
||||
function checkValidSignature(address _address, bytes _sig)
|
||||
function checkValidSignature(address _address, bytes _signature)
|
||||
public
|
||||
view
|
||||
returns (bool)
|
||||
{
|
||||
return isValidSignature(_address, _sig);
|
||||
return isValidSignature(_address, _signature);
|
||||
}
|
||||
|
||||
function onlyWithValidSignature(bytes _sig)
|
||||
function onlyWithValidSignature(bytes _signature)
|
||||
public
|
||||
onlyValidSignature(_sig)
|
||||
onlyValidSignature(_signature)
|
||||
view
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
function checkValidSignatureAndMethod(address _address, bytes _sig)
|
||||
function checkValidSignatureAndMethod(address _address, bytes _signature)
|
||||
public
|
||||
view
|
||||
returns (bool)
|
||||
{
|
||||
return isValidSignatureAndMethod(_address, _sig);
|
||||
return isValidSignatureAndMethod(_address, _signature);
|
||||
}
|
||||
|
||||
function onlyWithValidSignatureAndMethod(bytes _sig)
|
||||
function onlyWithValidSignatureAndMethod(bytes _signature)
|
||||
public
|
||||
onlyValidSignatureAndMethod(_sig)
|
||||
onlyValidSignatureAndMethod(_signature)
|
||||
view
|
||||
{
|
||||
|
||||
@ -40,18 +40,18 @@ contract SignatureBouncerMock is SignatureBouncer {
|
||||
address _address,
|
||||
bytes,
|
||||
uint,
|
||||
bytes _sig
|
||||
bytes _signature
|
||||
)
|
||||
public
|
||||
view
|
||||
returns (bool)
|
||||
{
|
||||
return isValidSignatureAndData(_address, _sig);
|
||||
return isValidSignatureAndData(_address, _signature);
|
||||
}
|
||||
|
||||
function onlyWithValidSignatureAndData(uint, bytes _sig)
|
||||
function onlyWithValidSignatureAndData(uint, bytes _signature)
|
||||
public
|
||||
onlyValidSignatureAndData(_sig)
|
||||
onlyValidSignatureAndData(_signature)
|
||||
view
|
||||
{
|
||||
|
||||
|
||||
@ -7,12 +7,12 @@ import "../ECRecovery.sol";
|
||||
contract ECRecoveryMock {
|
||||
using ECRecovery for bytes32;
|
||||
|
||||
function recover(bytes32 _hash, bytes _sig)
|
||||
function recover(bytes32 _hash, bytes _signature)
|
||||
public
|
||||
pure
|
||||
returns (address)
|
||||
{
|
||||
return _hash.recover(_sig);
|
||||
return _hash.recover(_signature);
|
||||
}
|
||||
|
||||
function toEthSignedMessageHash(bytes32 _hash)
|
||||
|
||||
@ -55,15 +55,15 @@ contract RBACMock is RBACWithAdmin {
|
||||
}
|
||||
|
||||
// admins can remove advisor's role
|
||||
function removeAdvisor(address _addr)
|
||||
function removeAdvisor(address _account)
|
||||
public
|
||||
onlyAdmin
|
||||
{
|
||||
// revert if the user isn't an advisor
|
||||
// (perhaps you want to soft-fail here instead?)
|
||||
checkRole(_addr, ROLE_ADVISOR);
|
||||
checkRole(_account, ROLE_ADVISOR);
|
||||
|
||||
// remove the advisor's role
|
||||
removeRole(_addr, ROLE_ADVISOR);
|
||||
removeRole(_account, ROLE_ADVISOR);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user