@merkl/api 0.19.25 → 0.19.26

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -46,7 +46,8 @@ const main = async () => {
46
46
  else if (status !== "LIVE" && campaign.startTimestamp > now)
47
47
  status = "SOON";
48
48
  }
49
- await OpportunityService.updateStatus(opportunity.id, status);
49
+ if (opportunity.status !== status)
50
+ await OpportunityService.updateStatus(opportunity.id, status);
50
51
  }
51
52
  // 3. Update the status of the opportunities associated to future campaigns
52
53
  const futureOpportunityIds = (await CampaignService.getFutureCampaigns({ computeChainId: chainId })).map(c => c.Opportunity.id);