Skip to content

Commit

Permalink
Add null check when accesing singlePortHarvesters. (#2078)
Browse files Browse the repository at this point in the history
  • Loading branch information
bgrozev authored Jan 12, 2024
1 parent e41cad1 commit 07b97eb
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ class JvbHealthChecker : HealthCheckService {
}

private fun hasValidAddress(): Boolean {
if (Harvesters.singlePortHarvesters.any { it.localAddress.address.isValid() }) {
if (Harvesters.singlePortHarvesters?.any { it.localAddress.address.isValid() } == true) {
return true
}
if (MappingCandidateHarvesters.getHarvesters().any { it.mask?.address?.isValid() == true }) {
Expand Down

0 comments on commit 07b97eb

Please sign in to comment.