Skip to content

Commit

Permalink
adjust wording
Browse files Browse the repository at this point in the history
Signed-off-by: Pascal Marco Caversaccio <pascal.caversaccio@hotmail.ch>
  • Loading branch information
pcaversaccio committed May 12, 2022
1 parent 4eff9de commit fb77a6e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Expand Up @@ -5,7 +5,7 @@
* `Clones`: optimize clone creation ([#3329](https://github.com/OpenZeppelin/openzeppelin-contracts/pull/3329))
* `TimelockController`: Migrate `_call` to `_execute` and allow inheritance and overriding similar to `Governor`. ([#3317](https://github.com/OpenZeppelin/openzeppelin-contracts/pull/3317))
* `CrossChainEnabledPolygonChild`: replace the `require` statement with the custom error `NotCrossChainCall`. ([#3380](https://github.com/OpenZeppelin/openzeppelin-contracts/pull/3380))
* `Strings`: add a new function `addressToHexString` that converts an `address` to its ASCII `string` hexadecimal representation with fixed length of 20 bytes. ([#3403](https://github.com/OpenZeppelin/openzeppelin-contracts/pull/3403))
* `Strings`: add a new function `addressToHexString` that converts an `address` with fixed length of 20 bytes to its ASCII `string` hexadecimal representation. ([#3403](https://github.com/OpenZeppelin/openzeppelin-contracts/pull/3403))

## 4.6.0 (2022-04-26)

Expand Down
2 changes: 1 addition & 1 deletion contracts/utils/Strings.sol
Expand Up @@ -67,7 +67,7 @@ library Strings {
}

/**
* @dev Converts an `address` to its ASCII `string` hexadecimal representation with fixed length of 20 bytes.
* @dev Converts an `address` with fixed length of 20 bytes to its ASCII `string` hexadecimal representation.
*/
function addressToHexString(address addr) internal pure returns (string memory) {
return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH);
Expand Down
2 changes: 1 addition & 1 deletion test/utils/Strings.test.js
Expand Up @@ -57,7 +57,7 @@ contract('Strings', function (accounts) {
});
});

describe('from address - fixed 20 bytes hex format', function () {
describe('from address - hex format', function () {
it('converts a random address', async function () {
expect(web3.utils.toChecksumAddress(await this.strings.fromAddressHex(this.strings.address)))
.to.equal(this.strings.address.toString());
Expand Down

0 comments on commit fb77a6e

Please sign in to comment.