Skip to content

Commit

Permalink
use the bw from the panel in location handler
Browse files Browse the repository at this point in the history
  • Loading branch information
jonesmac committed Nov 15, 2024
1 parent b66d068 commit f1a2c20
Showing 1 changed file with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -40,12 +40,11 @@ open class WitnessLocationHandler : WitnessHandlerInterface<List<XyoPayload?>> {

// target the first result because we are only looking at a single location witness
val apiResult = result.apiResults?.first()
if (apiResult?.response?.bw !== null) {
bw = apiResult.response.bw
}
if (apiResult?.errors?.size !== null && apiResult.errors.size > 0) {
apiResult.errors.forEach { error -> errors.add(error)}
}

bw = result.bw
}
}
if (errors.size > 0) return@withContext WitnessResult.Error(errors)
Expand Down

0 comments on commit f1a2c20

Please sign in to comment.