@wraps.dev/cli 2.20.5 → 2.20.6

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.
package/dist/cli.js CHANGED
@@ -18080,13 +18080,11 @@ async function createSESResources(config2) {
18080
18080
  });
18081
18081
  if (config2.eventTrackingEnabled) {
18082
18082
  const eventDestName = "wraps-email-eventbridge";
18083
- const opensEnabled = config2.trackingConfig?.opens ?? true;
18084
- const clicksEnabled = config2.trackingConfig?.clicks ?? true;
18085
18083
  const matchingEventTypes = [
18086
18084
  "SEND",
18087
18085
  "DELIVERY",
18088
- ...opensEnabled ? ["OPEN"] : [],
18089
- ...clicksEnabled ? ["CLICK"] : [],
18086
+ "OPEN",
18087
+ "CLICK",
18090
18088
  "BOUNCE",
18091
18089
  "COMPLAINT",
18092
18090
  "REJECT",
@@ -20463,9 +20461,11 @@ Run ${pc23.cyan("wraps email init")} first to deploy email infrastructure.
20463
20461
  opens: purpose === "marketing" || purpose === "notifications",
20464
20462
  clicks: purpose === "marketing" || purpose === "notifications"
20465
20463
  };
20466
- const baseEventTypes = [
20464
+ const matchingEventTypes = [
20467
20465
  "SEND",
20468
20466
  "DELIVERY",
20467
+ "OPEN",
20468
+ "CLICK",
20469
20469
  "BOUNCE",
20470
20470
  "COMPLAINT",
20471
20471
  "REJECT",
@@ -20473,7 +20473,6 @@ Run ${pc23.cyan("wraps email init")} first to deploy email infrastructure.
20473
20473
  "DELIVERY_DELAY",
20474
20474
  "SUBSCRIPTION"
20475
20475
  ];
20476
- const matchingEventTypes = trackingConfig.opens ? [...baseEventTypes, "OPEN", "CLICK"] : [...baseEventTypes];
20477
20476
  const eventBusArn = `arn:aws:events:${region}:${identity.accountId}:event-bus/default`;
20478
20477
  await progress.execute("Creating tracking configuration", async () => {
20479
20478
  try {
@@ -27786,7 +27785,7 @@ ${pc35.bold("SMTP Credentials for Legacy Systems")}
27786
27785
  }
27787
27786
  }
27788
27787
  );
27789
- const allEvents = [
27788
+ const matchingEventTypes = [
27790
27789
  EventType.SEND,
27791
27790
  EventType.DELIVERY,
27792
27791
  EventType.OPEN,
@@ -27798,12 +27797,6 @@ ${pc35.bold("SMTP Credentials for Legacy Systems")}
27798
27797
  EventType.DELIVERY_DELAY,
27799
27798
  EventType.SUBSCRIPTION
27800
27799
  ];
27801
- const trackingEnabled = d.trackingConfig != null ? d.trackingConfig : d.purpose === "transactional" || d.purpose === "notifications" ? { opens: false, clicks: false } : { opens: true, clicks: true };
27802
- const matchingEventTypes = allEvents.filter((evt) => {
27803
- if (evt === EventType.OPEN) return trackingEnabled.opens;
27804
- if (evt === EventType.CLICK) return trackingEnabled.clicks;
27805
- return true;
27806
- });
27807
27800
  await progress.execute(
27808
27801
  `Adding EventBridge destination for ${d.domain}`,
27809
27802
  async () => {