@dra2020/baseclient 1.0.94 → 1.0.95

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.
@@ -2575,21 +2575,25 @@ class GeoMultiCollection {
2575
2575
  }
2576
2576
  // Add the "all" collection from the passed in multi, but do not force compute of any things not computed yet.
2577
2577
  addAll(tag, multi) {
2578
- let nEntries = Util.countKeys(multi.entries);
2579
- if (nEntries) {
2580
- // Make sure all collection is created
2581
- if (!multi.all.topo && !multi.all.col && !multi.all.map) {
2582
- // Create cheapest one (collection if I need to create, otherwise copy from single entry)
2583
- if (nEntries > 1)
2584
- multi.allCol();
2585
- else {
2586
- let e = multi.nthEntry(0);
2587
- multi.all.topo = e.topo;
2588
- multi.all.col = e.col;
2589
- multi.all.map = e.map;
2578
+ if (multi == null || Util.isEmpty(multi.entries))
2579
+ this.remove(tag);
2580
+ else {
2581
+ let nEntries = Util.countKeys(multi.entries);
2582
+ if (nEntries) {
2583
+ // Make sure all collection is created
2584
+ if (!multi.all.topo && !multi.all.col && !multi.all.map) {
2585
+ // Create cheapest one (collection if I need to create, otherwise copy from single entry)
2586
+ if (nEntries > 1)
2587
+ multi.allCol();
2588
+ else {
2589
+ let e = multi.nthEntry(0);
2590
+ multi.all.topo = e.topo;
2591
+ multi.all.col = e.col;
2592
+ multi.all.map = e.map;
2593
+ }
2590
2594
  }
2595
+ this.add(tag, multi.all.topo, multi.all.col, multi.all.map);
2591
2596
  }
2592
- this.add(tag, multi.all.topo, multi.all.col, multi.all.map);
2593
2597
  }
2594
2598
  }
2595
2599
  remove(tag) {