From b941dcd71134f5be2e73ec6ee0a8aa50cf333ffb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=87a=C4=9Fla=20=C3=87elik?= Date: Wed, 4 Dec 2024 10:14:57 +0300 Subject: [PATCH] added taskId to event params --- src/BuyerAgent.sol | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/BuyerAgent.sol b/src/BuyerAgent.sol index 628ca9c..2b0faeb 100644 --- a/src/BuyerAgent.sol +++ b/src/BuyerAgent.sol @@ -58,10 +58,10 @@ contract BuyerAgent is Ownable { event PurchaseRequest(uint256 indexed taskId, uint256 indexed round); /// @notice Emitted when a purchase is made. - event Purchase(uint256 indexed round); + event Purchase(uint256 indexed taskId, uint256 indexed round); /// @notice Emitted when the state is updated. - event StateUpdate(uint256 indexed round); + event StateUpdate(uint256 indexed taskId, uint256 indexed round); /*////////////////////////////////////////////////////////////// STORAGE @@ -235,7 +235,7 @@ contract BuyerAgent is Ownable { // update taskId as completed isOracleRequestProcessed[taskId] = true; - emit StateUpdate(round); + emit StateUpdate(taskId, round); } /// @notice Function to buy the asset from the Swan with the given assed address. @@ -277,7 +277,7 @@ contract BuyerAgent is Ownable { // update taskId as completed isOracleRequestProcessed[taskId] = true; - emit Purchase(round); + emit Purchase(taskId, round); } /// @notice Function to withdraw the tokens from the contract.