@@ -142,18 +142,18 @@ export class LoanProductAccountingStepComponent implements OnInit, OnChanges {
142
142
enableAccrualActivityPosting : this . loanProductsTemplate . enableAccrualActivityPosting
143
143
} ) ;
144
144
if ( this . deferredIncomeRecognition ) {
145
- if ( this . deferredIncomeRecognition . capitalizedIncome . enableIncomeCapitalization ) {
145
+ if ( this . deferredIncomeRecognition . capitalizedIncome ? .enableIncomeCapitalization ) {
146
146
this . loanProductAccountingForm . patchValue ( {
147
147
deferredIncomeLiabilityAccountId : accountingMappings . deferredIncomeLiabilityAccount . id ,
148
148
incomeFromCapitalizationAccountId : accountingMappings . incomeFromCapitalizationAccount . id
149
149
} ) ;
150
150
}
151
- if ( this . deferredIncomeRecognition . buyDownFee . enableBuyDownFee ) {
151
+ if ( this . deferredIncomeRecognition . buyDownFee ? .enableBuyDownFee ) {
152
152
this . loanProductAccountingForm . patchValue ( {
153
153
deferredIncomeLiabilityAccountId : accountingMappings . deferredIncomeLiabilityAccount . id ,
154
154
incomeFromBuyDownAccountId : accountingMappings . incomeFromBuyDownAccount . id
155
155
} ) ;
156
- if ( this . deferredIncomeRecognition . buyDownFee . merchantBuyDownFee ) {
156
+ if ( this . deferredIncomeRecognition . buyDownFee ? .merchantBuyDownFee ) {
157
157
this . loanProductAccountingForm . patchValue ( {
158
158
buyDownExpenseAccountId : accountingMappings . buyDownExpenseAccount ?. id
159
159
} ) ;
@@ -599,8 +599,8 @@ export class LoanProductAccountingStepComponent implements OnInit, OnChanges {
599
599
if ( this . isAccountingAccrualBased ) {
600
600
if ( this . deferredIncomeRecognition ) {
601
601
if (
602
- this . deferredIncomeRecognition . capitalizedIncome . enableIncomeCapitalization ||
603
- this . deferredIncomeRecognition . buyDownFee . enableBuyDownFee
602
+ this . deferredIncomeRecognition . capitalizedIncome ? .enableIncomeCapitalization ||
603
+ this . deferredIncomeRecognition . buyDownFee ? .enableBuyDownFee
604
604
) {
605
605
this . loanProductAccountingForm . addControl (
606
606
'deferredIncomeLiabilityAccountId' ,
@@ -609,16 +609,16 @@ export class LoanProductAccountingStepComponent implements OnInit, OnChanges {
609
609
} else {
610
610
this . loanProductAccountingForm . removeControl ( 'deferredIncomeLiabilityAccountId' ) ;
611
611
}
612
- if ( this . deferredIncomeRecognition . capitalizedIncome . enableIncomeCapitalization ) {
612
+ if ( this . deferredIncomeRecognition . capitalizedIncome ? .enableIncomeCapitalization ) {
613
613
this . loanProductAccountingForm . addControl (
614
614
'incomeFromCapitalizationAccountId' ,
615
615
new UntypedFormControl ( '' , Validators . required )
616
616
) ;
617
617
} else {
618
618
this . loanProductAccountingForm . removeControl ( 'incomeFromCapitalizationAccountId' ) ;
619
619
}
620
- if ( this . deferredIncomeRecognition . buyDownFee . enableBuyDownFee ) {
621
- if ( this . deferredIncomeRecognition . buyDownFee . merchantBuyDownFee ) {
620
+ if ( this . deferredIncomeRecognition . buyDownFee ? .enableBuyDownFee ) {
621
+ if ( this . deferredIncomeRecognition . buyDownFee ? .merchantBuyDownFee ) {
622
622
this . loanProductAccountingForm . addControl (
623
623
'buyDownExpenseAccountId' ,
624
624
new UntypedFormControl ( '' , Validators . required )
0 commit comments