diff --git a/core/src/com/unciv/ui/civilopedia/CivilopediaScreen.kt b/core/src/com/unciv/ui/civilopedia/CivilopediaScreen.kt index 1a09ef6dff..101eee1068 100644 --- a/core/src/com/unciv/ui/civilopedia/CivilopediaScreen.kt +++ b/core/src/com/unciv/ui/civilopedia/CivilopediaScreen.kt @@ -221,7 +221,8 @@ class CivilopediaScreen( buttonTable.defaults().pad(10f) var currentX = 10f // = padLeft - for (categoryKey in categoryToEntries.keys) { + for ((categoryKey, entries) in categoryToEntries) { + if (entries.isEmpty()) continue val icon = if (categoryKey.headerIcon.isNotEmpty()) ImageGetter.getImage(categoryKey.headerIcon) else null val button = IconTextButton(categoryKey.label, icon) button.addTooltip(categoryKey.key)