From 8fe55c11ef6c268eb3f0ac8efd834d20efb661fb Mon Sep 17 00:00:00 2001 From: Krishang Date: Tue, 8 Nov 2022 20:55:38 +0530 Subject: [PATCH] replace RequestExecuted with TokensClaimed --- contracts/tiered-drop/TieredDrop.sol | 17 ++++++++++++++++- docs/TieredDrop.md | 20 ++++++++++++++++++++ 2 files changed, 36 insertions(+), 1 deletion(-) diff --git a/contracts/tiered-drop/TieredDrop.sol b/contracts/tiered-drop/TieredDrop.sol index 8c8f6851b..976d560af 100644 --- a/contracts/tiered-drop/TieredDrop.sol +++ b/contracts/tiered-drop/TieredDrop.sol @@ -99,6 +99,19 @@ contract TieredDrop is /// @dev Mapping from hash(tier, "minted") -> total minted in tier. mapping(bytes32 => uint256) private totalsForTier; + /*/////////////////////////////////////////////////////////////// + Events + //////////////////////////////////////////////////////////////*/ + + /// @notice Emitted when tokens are claimed via `claimWithSignature`. + event TokensClaimed( + address indexed claimer, + address indexed receiver, + uint256 startTokenId, + uint256 quantityClaimed, + string[] tiersInPriority + ); + /*/////////////////////////////////////////////////////////////// Constructor + initializer logic //////////////////////////////////////////////////////////////*/ @@ -261,7 +274,9 @@ contract TieredDrop is // Mint tokens. transferTokensOnClaim(to, quantity, tiersInPriority); - emit RequestExecuted(_msgSender(), signer, _req); + emit TokensClaimed(_msgSender(), to, tokenIdToMint, quantity, tiersInPriority); + + // emit RequestExecuted(_msgSender(), signer, _req); } /*/////////////////////////////////////////////////////////////// diff --git a/docs/TieredDrop.md b/docs/TieredDrop.md index d20ebbda6..a5018039e 100644 --- a/docs/TieredDrop.md +++ b/docs/TieredDrop.md @@ -1336,6 +1336,26 @@ event TokenURIRevealed(uint256 indexed index, string revealedURI) | index `indexed` | uint256 | undefined | | revealedURI | string | undefined | +### TokensClaimed + +```solidity +event TokensClaimed(address indexed claimer, address indexed receiver, uint256 startTokenId, uint256 quantityClaimed, string[] tiersInPriority) +``` + +Emitted when tokens are claimed via `claimWithSignature`. + + + +#### Parameters + +| Name | Type | Description | +|---|---|---| +| claimer `indexed` | address | undefined | +| receiver `indexed` | address | undefined | +| startTokenId | uint256 | undefined | +| quantityClaimed | uint256 | undefined | +| tiersInPriority | string[] | undefined | + ### TokensLazyMinted ```solidity