From 23eed15d39063d2752f2f014cfe58b1085fd5ac8 Mon Sep 17 00:00:00 2001 From: Pablo Veyrat Date: Fri, 22 Dec 2023 13:01:42 +0100 Subject: [PATCH] feat: update creator --- contracts/DistributionCreator.sol | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contracts/DistributionCreator.sol b/contracts/DistributionCreator.sol index 3246e1f..07f5e6c 100644 --- a/contracts/DistributionCreator.sol +++ b/contracts/DistributionCreator.sol @@ -299,7 +299,7 @@ contract DistributionCreator is UUPSHelper, ReentrancyGuardUpgradeable { (campaignAmountMinusFees, campaignId) = _computeFees(_fees, campaign.amount, campaign.rewardToken); campaign.amount = campaignAmountMinusFees; campaign.campaignId = campaignId; - campaign.creator = msg.sender; + if (campaign.creator == address(0)) campaign.creator = msg.sender; uint256 lookupIndex = campaignList.length; campaignLookup[campaignId] = lookupIndex; campaignList.push(campaign);