771f07aa5f
Fix docs navigation
...
(cherry picked from commit 3fe65ef467 )
2022-02-16 18:51:22 -03:00
a5445b0afb
4.5.0
v4.5.0
2022-02-09 16:05:24 -03:00
494b1b9a39
Add a _spendAllowance function to ERC20 & ERC777 ( #3170 )
...
(cherry picked from commit c5a6cae898 )
2022-02-09 13:30:46 -03:00
234a971410
Rename some ERC20 parameters to match the standard document. ( #3167 )
...
* Renames `sender` to `source`.
The naming variable was incorrect. The source of the funds is *not* necessarily (and in most cases isn't) the sender of the transaction. Also, this code has a `msgSender` which further adds confusion.
* Changes to `from/to` instead of `source`.
* Function documentation matches new names
* Changed other instances of sender/recipient to from/to.
Also changed `msgSender` to `owner` in the approval related methods.
* apply changes to IERC20.sol + minor renaming in ERC20.sol
Co-authored-by: Daniel Von Fange <daniel@leancoder.com >
Co-authored-by: Hadrien Croubois <hadrien.croubois@gmail.com >
(cherry picked from commit 63b466901f )
2022-02-09 13:29:42 -03:00
2248e3749d
Fix typo in CHANGELOG ( #3138 )
...
Remove repeated word "the".
(cherry picked from commit ae54e6de1d )
Signed-off-by: Hadrien Croubois <hadrien.croubois@gmail.com >
2022-02-08 10:00:00 +01:00
c1a5c2713b
Make royaltyInfo(uint256 _tokenId, uint256 _salePrice) virtual ( #3133 )
...
* Make royaltyInfo(uint256 _tokenId, uint256 _salePrice) virtual
Should be cherrypicked in release 4.5
* fix lint
(cherry picked from commit 6fb1e843cf )
Signed-off-by: Hadrien Croubois <hadrien.croubois@gmail.com >
2022-02-08 09:56:27 +01:00
a9760237e6
Fix broken pull request links in change log ( #3114 )
...
Co-authored-by: Han Lin Yap <codler@users.noreply.github.com >
(cherry picked from commit 25eeb80b18 )
Signed-off-by: Hadrien Croubois <hadrien.croubois@gmail.com >
2022-02-08 09:56:07 +01:00
fdfd9726e1
Move abs(int256) from Math to SafeMath ( #3110 )
...
Co-authored-by: Francisco Giordano <frangio.1@gmail.com >
(cherry picked from commit 3eb2d43b06 )
Signed-off-by: Hadrien Croubois <hadrien.croubois@gmail.com >
2022-02-08 09:55:29 +01:00
a8a08bef58
Improve documentation of various governance aspects ( #3161 )
...
Co-authored-by: Hadrien Croubois <hadrien.croubois@gmail.com >
(cherry picked from commit 85566faeb2 )
2022-02-02 13:36:17 -03:00
ac8c53612a
Add "available since" on Base64.sol
...
(cherry picked from commit bfd05d9646 )
2022-02-01 20:04:41 -03:00
a9e5759711
Simplify inheritance to avoid overrides
...
(cherry picked from commit fc01c51c13 )
2022-01-31 22:07:26 -03:00
6b6e1b5eb1
Add function documentation for SignatureChecker.
...
(cherry picked from commit f55d2716a8 )
2022-01-28 22:45:26 -03:00
13bf45a657
Lint
...
(cherry picked from commit d57593c148 )
2022-01-24 00:42:55 -03:00
40104483e4
Add workflow to generate and update docs branches
...
(cherry picked from commit 7c47ac7193 )
2022-01-23 22:33:29 -03:00
d1f67bd803
4.5.0-rc.0
v4.5.0-rc.0
2022-01-13 20:10:47 -03:00
ecae978cb5
Make more functions virtual ( #3078 )
...
Co-authored-by: Francisco Giordano <frangio.1@gmail.com >
2022-01-13 18:56:36 +00:00
e192fac276
Simplify UUPSUpgradeable along the lines of ERC1822 ( #3021 )
...
Co-authored-by: Francisco Giordano <frangio.1@gmail.com >
2022-01-13 15:46:55 -03:00
3458c1e854
Add SignedMath with math utilities for signed integers ( #2686 )
...
* add contract and tests
* avoid implicit cast
* add test cases
* fix test names
* modify avarage and add tests
* improve signed average formula
* fix lint
* better average formula
* refactor signed average testing
* add doc and changelog entry
* Update contracts/utils/math/SignedMath.sol
Co-authored-by: Francisco Giordano <frangio.1@gmail.com >
* remove ceilDiv
Co-authored-by: Hadrien Croubois <hadrien.croubois@gmail.com >
Co-authored-by: Francisco Giordano <frangio.1@gmail.com >
2022-01-12 20:08:59 +01:00
dee772a55f
Add documentation to TokenTimelock
2022-01-12 11:51:09 -03:00
1051db3802
Use abi.encodePacked instead of bytes.concat
2022-01-11 16:51:55 -03:00
a8f35b6c25
Make script executable
2022-01-11 16:41:59 -03:00
c366de3626
Fix encoding of signature+calldata in GovernorCompatibilityBravo ( #3100 )
...
Co-authored-by: Francisco Giordano <frangio.1@gmail.com >
2022-01-11 15:45:06 -03:00
80d8da0564
Do not reduce approval on transferFrom if current allowance is type(uint256).max ( #3085 )
...
* add feature request #3084
* Update contracts/token/ERC20/ERC20.sol
Co-authored-by: Francisco Giordano <frangio.1@gmail.com >
* Add changelog note
* add documentation
* test unlimitted allowance and add ERC777 unlimitted allowance
* reference PR in changelog
* documentation IERC20 -> ERC20
* use asciidoc note syntax
* use asciidoc note syntax
* typo
* typos
Co-authored-by: Hadrien Croubois <hadrien.croubois@gmail.com >
Co-authored-by: Francisco Giordano <frangio.1@gmail.com >
2022-01-11 00:08:33 +01:00
fd7c4ba8f0
Update pragma in utils/Address.sol to 0.8.1 ( #3098 )
2022-01-10 19:47:43 -03:00
8dd744fc18
Add missing reference to PR in changelog
2022-01-09 17:50:05 +01:00
828fe365ee
Normalize return variable names in IERC721Enumerable ( #3079 )
...
* Name missing return variable in IERC721Enumerable
For consistency among all functions.
* remove return variable names
2022-01-07 15:39:46 +01:00
a65c03bc0d
Implement Non Fungible Token Royalty (EIP2981) ( #3012 )
...
Co-authored-by: Francisco Giordano <frangio.1@gmail.com >
Co-authored-by: Hadrien Croubois <hadrien.croubois@gmail.com >
2022-01-06 19:34:57 -03:00
1e815f3308
Restructure intro to ERC721 contract docs
2022-01-06 17:45:21 -03:00
d74605641c
Fix typos ( #3075 )
...
Correct a couple of misspellings.
2022-01-05 10:13:30 +01:00
a9f994f063
Reduce ERC20 allowance before triggering transfer ( #3056 )
...
* Reduce ERC20 allowance before triggering transfer
* adapt ERC777 to reduce allowance before transfer
* fix test for ERC777
* use smaller number to reduce balance
* simplify test description
* don't use deprecated expectEvents.inLogs
* fix test
Co-authored-by: Hadrien Croubois <hadrien.croubois@gmail.com >
2021-12-31 09:17:12 +00:00
ef0273fde1
Add Base64 library to utils ( #2884 )
...
* Add Base64 library to utils
* Fix typo on Base64 padding
* Added documentation for Base64 and references from ERC1155 and ERC721
* Updated Changelog
* Fix typo in utilities doc
* use mstore8 to improve memory accesses
* use shorter strings with encodePacked
* do not use using-for syntax, for clarity
Co-authored-by: Hadrien Croubois <hadrien.croubois@gmail.com >
Co-authored-by: Francisco Giordano <frangio.1@gmail.com >
2021-12-29 20:41:20 +01:00
da3a9ae18b
Avoid assembly in signature V and S decomposition ( #3060 )
...
* Avoid assembly in signature V and S decomposition
* Update ECDSA.sol
2021-12-29 16:22:39 +01:00
e3391cd65f
Fix typo ( #3058 )
2021-12-28 21:52:00 -03:00
e9e177f53b
Fix ERC2771ContextMock for upgradeable contracts
2021-12-27 21:26:47 -03:00
fe38eae6cd
Re-enable immutable forwarder in ERC2771Context ( #2917 )
...
Co-authored-by: Francisco Giordano <frangio.1@gmail.com >
2021-12-27 21:21:56 -03:00
915ca181ba
Add Certora's Governance verification rules ( #2997 )
...
Co-authored-by: Shelly Grossman <shelly@certora.com >
Co-authored-by: Aleksander Kryukov <58052996+RedLikeRosesss@users.noreply.github.com >
Co-authored-by: Michael M <91594326+MichaelMorami@users.noreply.github.com >
Co-authored-by: Aleksander Kryukov <firealexkryukov@gmail.com >
2021-12-27 19:11:59 -03:00
a0a8bbb57f
Remove note about enabling self-delegation
2021-12-27 12:24:37 -03:00
1ffcb10bd2
Change release script to only update version comment for changed files ( #3033 )
...
Co-authored-by: Francisco Giordano <frangio.1@gmail.com >
2021-12-22 19:21:45 -03:00
10c8fcd3b8
Use invalid opcode to consume all gas in MinimalForwarder ( #3035 )
2021-12-22 19:01:24 -03:00
cafd900ad6
Fix memory leak in merkle verification ( #3039 )
2021-12-21 17:01:28 -03:00
e667ec9533
Add Governor Timelock Control Warning ( #3032 )
...
Co-authored-by: Francisco Giordano <frangio.1@gmail.com >
2021-12-20 17:00:13 -03:00
5ac4d93ae3
Add missing letter ( #3034 )
2021-12-17 15:46:45 +00:00
0550d13aee
Add ERC721 import in tutorial
2021-12-16 18:29:31 -03:00
d95cdaae8e
Replace excodesize assembly with address.code.length ( https://github.com/ethereum/solidity/releases/tag/v0.8.1 ) ( #3025 )
2021-12-15 18:54:10 +01:00
4a9cc8b491
Merge branch 'release-v4.4'
2021-12-14 13:34:03 -03:00
6bd6b76d11
4.4.1
v4.4.1
2021-12-14 13:14:39 -03:00
13a6ec753a
Remove bad date from changelog
2021-12-14 13:14:21 -03:00
bda61cd5e5
Fix typo ( #3016 )
2021-12-12 22:55:19 +01:00
b42b05311b
Add ERC721Votes for NFT-based governance ( #2944 )
...
Co-authored-by: Francisco Giordano <frangio.1@gmail.com >
Co-authored-by: Hadrien Croubois <hadrien@openzeppelin.com >
2021-12-10 18:58:45 -03:00
553c8fdec7
Update initializer modifier to prevent reentrancy during initialization ( #3006 )
...
Co-authored-by: Francisco Giordano <frangio.1@gmail.com >
(cherry picked from commit 08840b9f8c )
2021-12-10 13:10:17 -03:00