Skip to content

Commit d92853d

Browse files
committed
HIA-765 - minor refactor
1 parent 7813e3b commit d92853d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/main/kotlin/uk/gov/justice/digital/hmpps/hmppsintegrationapi/services/GetCellLocationForPersonService.kt

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ class GetCellLocationForPersonService(
1313
) {
1414
fun execute(hmppsId: String): Response<CellLocation?> {
1515

16-
val prisonResponse = when {
17-
isNomsNumber(hmppsId) -> prisonerOffenderSearchGateway.getPrisonOffender(nomsNumber = hmppsId)
16+
val prisonResponse = when (isNomsNumber(hmppsId)) {
17+
true -> prisonerOffenderSearchGateway.getPrisonOffender(nomsNumber = hmppsId)
1818
else -> {
1919
val personResponse = getPersonService.execute(hmppsId = hmppsId)
2020

0 commit comments

Comments
 (0)