WEB-639: Refactor redundant boolean comparisons (#3063)

improve

improve

improve

improve
This commit is contained in:
Shubham Kumar
2026-01-31 07:07:59 -06:00
committed by GitHub
parent 41a71cd269
commit fbee49b464
55 changed files with 190 additions and 193 deletions
@@ -720,6 +720,6 @@ export class LoansAccountTermsStepComponent implements OnInit, OnChanges {
* Available when PROGRESSIVE schedule type and multi-disbursement is enabled.
*/
isFullTermTrancheEditable(): boolean {
return this.isProgressive && this.multiDisburseLoan === true;
return this.isProgressive && !!this.multiDisburseLoan;
}
}
@@ -87,7 +87,7 @@ export class PenaltyManagementService {
}
// Check if it's a penalty charge
const isPenalty =
charge.penalty === true ||
charge.penalty ||
charge.penalty === 'true' ||
(charge.chargeTimeType &&
(charge.chargeTimeType.value?.toLowerCase().includes('overdue') ||
@@ -99,7 +99,7 @@ export class PenaltyManagementService {
}
// Check if already waived or paid
if (charge.waived === true || charge.waived === 'true' || charge.paid === true || charge.paid === 'true') {
if (charge.waived || charge.waived === 'true' || charge.paid || charge.paid === 'true') {
return false;
}