Skip to content

Commit

Permalink
Forgot the 'or' check
Browse files Browse the repository at this point in the history
  • Loading branch information
quickdesh committed Jun 28, 2024
1 parent 2291b92 commit 7b0a368
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -145,12 +145,14 @@ data class ItemDto(
name = if (removeAffixes && prefix.isNotBlank()) prefix else "${prefix}Movie"
}
EpisodeType.EPISODE -> {
name = if (indexNumber == null) {
name = if (indexNumber == null || removeAffixes) {
"${prefix}${this@ItemDto.name}"
} else {
episode_number = indexNumber.toFloat()
"${prefix}Ep. $indexNumber - ${this@ItemDto.name}"
}
indexNumber?.let {
episode_number = it.toFloat()
}
}
}

Expand Down

0 comments on commit 7b0a368

Please sign in to comment.