From bb6a24023f0b348c147de3c56000a85ab169ffdc Mon Sep 17 00:00:00 2001 From: Daniel Beal Date: Sun, 15 Oct 2023 20:03:17 +0900 Subject: [PATCH] adding notify reward amount to the trading rewards otherwise sending rewards to l2 will fail --- contracts/TradingRewards.sol | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/contracts/TradingRewards.sol b/contracts/TradingRewards.sol index 2563d2abe2..dd32976553 100644 --- a/contracts/TradingRewards.sol +++ b/contracts/TradingRewards.sol @@ -4,6 +4,7 @@ pragma solidity ^0.5.16; import "./Pausable.sol"; import "./MixinResolver.sol"; import "./Owned.sol"; +import "./RewardsDistributionRecipient.sol"; // External dependencies. import "openzeppelin-solidity-2.3.0/contracts/token/ERC20/SafeERC20.sol"; @@ -17,7 +18,7 @@ import "./interfaces/ITradingRewards.sol"; import "./interfaces/IExchanger.sol"; // https://docs.synthetix.io/contracts/source/contracts/tradingrewards -contract TradingRewards is ITradingRewards, ReentrancyGuard, Owned, Pausable, MixinResolver { +contract TradingRewards is ITradingRewards, ReentrancyGuard, Owned, Pausable, MixinResolver, RewardsDistributionRecipient { using SafeMath for uint; using SafeDecimalMath for uint; using SafeERC20 for IERC20; @@ -256,6 +257,8 @@ contract TradingRewards is ITradingRewards, ReentrancyGuard, Owned, Pausable, Mi emit AssignedRewardTokensRecovered(recoverAddress, amount, periodID); } + function notifyRewardAmount(uint256 reward) external {} + function _validateRecoverAddress(address recoverAddress) internal view { if (recoverAddress == address(0) || recoverAddress == address(this)) { revert("Invalid recover address");