Skip to content

Commit

Permalink
use first() instead of index operator
Browse files Browse the repository at this point in the history
(per suggestion)
  • Loading branch information
zealerker22 authored Jul 7, 2024
1 parent fb93dd6 commit 6aee7a9
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -603,7 +603,7 @@ object ItemFeatures {
val parts = enchant.loreName.split(" ")
val joined = if (parts.size > 1) parts.joinToString("") { it[0].uppercase() }
else if (parts[0].startsWith("Turbo-")) "${
parts[0].split("-")[1].take(3).toTitleCase()
parts[0].split("-").first().take(3).toTitleCase()
}."
else "${
parts[0].take(3).toTitleCase()
Expand Down

0 comments on commit 6aee7a9

Please sign in to comment.