Skip to content

Commit

Permalink
Show favorites only if selected server has favorites (#3729)
Browse files Browse the repository at this point in the history
  • Loading branch information
dshokouhi authored Jul 28, 2023
1 parent 8f7abb4 commit 447ad5e
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,8 @@ class MainVehicleScreen(
setLoading(true)
}.build()
}
val listBuilder = if (favoritesList.isNotEmpty()) {
val serverHasFavorites = favoritesList.any { it.split("-")[0].toIntOrNull() == serverId.value }
val listBuilder = if (serverHasFavorites) {
EntityGridVehicleScreen(
carContext,
serverManager,
Expand Down

0 comments on commit 447ad5e

Please sign in to comment.