@salesforce/core-bundle 8.1.0 → 8.1.1

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/lib/index.d.ts CHANGED
@@ -1790,7 +1790,7 @@ declare module '@salesforce/core-bundle/lifecycleEvents' {
1790
1790
  */
1791
1791
  emit<T = AnyJson>(eventName: string, data: T): Promise<void>;
1792
1792
  }
1793
- export const cloneUniqueListeners: (uniqueListeners: UniqueListenerMap) => UniqueListenerMap;
1793
+ export const cloneUniqueListeners: (uniqueListeners: UniqueListenerMap | undefined) => UniqueListenerMap;
1794
1794
  export {};
1795
1795
 
1796
1796
  }
package/lib/index.js CHANGED
@@ -12088,7 +12088,7 @@ var require_package2 = __commonJS({
12088
12088
  "package.json"(exports2, module2) {
12089
12089
  module2.exports = {
12090
12090
  name: "@salesforce/core-bundle",
12091
- version: "8.1.0",
12091
+ version: "8.1.1",
12092
12092
  description: "Core libraries to interact with SFDX projects, orgs, and APIs.",
12093
12093
  main: "lib/index",
12094
12094
  types: "lib/index.d.ts",
@@ -12446,7 +12446,10 @@ var require_lifecycleEvents = __commonJS({
12446
12446
  };
12447
12447
  exports2.Lifecycle = Lifecycle;
12448
12448
  var cloneListeners = (listeners) => new Map(Array.from(listeners.entries()));
12449
- var cloneUniqueListeners = (uniqueListeners) => new Map(Array.from(uniqueListeners.entries()).map(([key, value]) => [key, cloneListeners(value)]));
12449
+ var cloneUniqueListeners = (uniqueListeners) => (
12450
+ // in case we're crossing major sfdx-core versions where uniqueListeners might be undefined
12451
+ new Map(Array.from(uniqueListeners?.entries() ?? []).map(([key, value]) => [key, cloneListeners(value)]))
12452
+ );
12450
12453
  exports2.cloneUniqueListeners = cloneUniqueListeners;
12451
12454
  }
12452
12455
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@salesforce/core-bundle",
3
- "version": "8.1.0",
3
+ "version": "8.1.1",
4
4
  "description": "Core libraries to interact with SFDX projects, orgs, and APIs.",
5
5
  "main": "lib/index",
6
6
  "types": "lib/index.d.ts",