@hmcts/ccpay-web-component 5.0.1-beta170 → 5.0.1-beta171

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.
@@ -6463,23 +6463,25 @@ class AddRemissionComponent {
6463
6463
  refundFeesList() {
6464
6464
  /** @type {?} */
6465
6465
  const creds = (/** @type {?} */ (this.remissionForm.controls.feesList));
6466
- for (var i = 0; i < this.fees.length; i++) {
6467
- creds.push(this.formBuilder.group({
6468
- id: this.fees[i].id,
6469
- code: this.fees[i].code,
6470
- volume: this.fees[i].volume,
6471
- calculated_amount: this.fees[i].calculated_amount,
6472
- apportion_amount: this.fees[i].apportion_amount,
6473
- ccd_case_number: this.fees[i].ccd_case_number,
6474
- description: this.fees[i].description,
6475
- net_amount: this.fees[i].net_amount,
6476
- version: this.fees[i].version,
6477
- amounttorefund: [''],
6478
- selected: [''],
6479
- updatedVolume: ''
6480
- }));
6466
+ if (creds.controls.length > 0) {
6467
+ for (var i = 0; i < this.fees.length; i++) {
6468
+ creds.push(this.formBuilder.group({
6469
+ id: this.fees[i].id,
6470
+ code: this.fees[i].code,
6471
+ volume: this.fees[i].volume,
6472
+ calculated_amount: this.fees[i].calculated_amount,
6473
+ apportion_amount: this.fees[i].apportion_amount,
6474
+ ccd_case_number: this.fees[i].ccd_case_number,
6475
+ description: this.fees[i].description,
6476
+ net_amount: this.fees[i].net_amount,
6477
+ version: this.fees[i].version,
6478
+ amounttorefund: [''],
6479
+ selected: [''],
6480
+ updatedVolume: ''
6481
+ }));
6482
+ }
6483
+ this.cd.detectChanges();
6481
6484
  }
6482
- this.cd.detectChanges();
6483
6485
  }
6484
6486
  /**
6485
6487
  * @return {?}