Optimize collection creation in Navigation.kt (#180)
* ⚡ Optimize collection creation in Navigation.kt Replaced uses of `.map { ... }.toSet()` with `.mapTo(mutableSetOf()) { ... }` in Navigation.kt. This avoids the creation of intermediate ArrayList objects, saving unnecessary memory allocations. * ⚡ Optimize collection creation in Navigation.kt Replaced uses of `.map { ... }.toSet()` with `.mapTo(mutableSetOf()) { ... }` in Navigation.kt. This avoids the creation of intermediate ArrayList objects, saving unnecessary memory allocations. Fixed ktlint formatting issues causing CI failure.
This commit is contained in:
6 files changed
+71
-13
No files matched your search
@@ -812,12 +812,11 @@ private fun RichText(
|
||||
}
|
||||
|
||||
private val TIMESTAMP_FORMATTER =
|
||||
DateTimeFormatter.ofPattern("HH:mm")
|
||||
DateTimeFormatter
|
||||
.ofPattern("HH:mm")
|
||||
.withZone(ZoneId.systemDefault())
|
||||
|
||||
private fun formatTimestamp(timestamp: Long): String {
|
||||
return TIMESTAMP_FORMATTER.format(Instant.ofEpochMilli(timestamp))
|
||||
}
|
||||
private fun formatTimestamp(timestamp: Long): String = TIMESTAMP_FORMATTER.format(Instant.ofEpochMilli(timestamp))
|
||||
|
||||
/**
|
||||
* Build an AnnotatedString with search matches highlighted.
|
||||
|
||||
Reference in new issue
Block a user