From 6d74b913885d729b5c72209aa03c4b68a33c794c Mon Sep 17 00:00:00 2001 From: Hadrien Croubois Date: Sat, 8 Jul 2023 03:23:28 +0200 Subject: [PATCH] Remove superfluous receive() function from Proxy.sol (#4434) Co-authored-by: Francisco Giordano --- .changeset/eight-peaches-guess.md | 5 +++++ contracts/proxy/Proxy.sol | 8 -------- 2 files changed, 5 insertions(+), 8 deletions(-) create mode 100644 .changeset/eight-peaches-guess.md diff --git a/.changeset/eight-peaches-guess.md b/.changeset/eight-peaches-guess.md new file mode 100644 index 000000000..ba4e87c17 --- /dev/null +++ b/.changeset/eight-peaches-guess.md @@ -0,0 +1,5 @@ +--- +'openzeppelin-solidity': minor +--- + +`Proxy`: Removed redundant `receive` function. diff --git a/contracts/proxy/Proxy.sol b/contracts/proxy/Proxy.sol index c2875aeac..8c8925b9b 100644 --- a/contracts/proxy/Proxy.sol +++ b/contracts/proxy/Proxy.sol @@ -68,14 +68,6 @@ abstract contract Proxy { _fallback(); } - /** - * @dev Fallback function that delegates calls to the address returned by `_implementation()`. Will run if call data - * is empty. - */ - receive() external payable virtual { - _fallback(); - } - /** * @dev Hook that is called before falling back to the implementation. Can happen as part of a manual `_fallback` * call, or as part of the Solidity `fallback` or `receive` functions.