gamma-app-controller 1.1.2 → 1.1.3

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.
@@ -8776,11 +8776,21 @@ class CreateDatasetSqlComponent {
8776
8776
  this.apiBulderDataset.queryConfig.enrichments.splice(newPosition, 0, itemToMove);
8777
8777
  }
8778
8778
  addColumns() {
8779
- let obj = {
8780
- "columnName": "",
8781
- "enrichFunction": "",
8782
- };
8783
- this.apiBulderDataset.queryConfig.enrichments.push(obj);
8779
+ if (this.apiBulderDataset.queryConfig.enrichments && this.apiBulderDataset.queryConfig.enrichments.length !== 0) {
8780
+ let obj = {
8781
+ "columnName": "",
8782
+ "enrichFunction": "",
8783
+ };
8784
+ this.apiBulderDataset.queryConfig.enrichments.push(obj);
8785
+ }
8786
+ else {
8787
+ this.apiBulderDataset.queryConfig.enrichments = [];
8788
+ let obj = {
8789
+ "columnName": "",
8790
+ "enrichFunction": "",
8791
+ };
8792
+ this.apiBulderDataset.queryConfig.enrichments.push(obj);
8793
+ }
8784
8794
  }
8785
8795
  deleteColumns(i) {
8786
8796
  this.apiBulderDataset.queryConfig.enrichments.splice(i, 1);