diff --git a/src/main/kotlin/nl/avisi/structurizr/site/generatr/site/model/DiagramIndexListViewModel.kt b/src/main/kotlin/nl/avisi/structurizr/site/generatr/site/model/DiagramIndexListViewModel.kt index 958d5bc6..589b042b 100644 --- a/src/main/kotlin/nl/avisi/structurizr/site/generatr/site/model/DiagramIndexListViewModel.kt +++ b/src/main/kotlin/nl/avisi/structurizr/site/generatr/site/model/DiagramIndexListViewModel.kt @@ -2,7 +2,7 @@ package nl.avisi.structurizr.site.generatr.site.model data class DiagramIndexListViewModel( - val diagrams: List?, - val images: List?, - val showList: Boolean = ((diagrams?.count() ?: 0) + (images?.count() ?: 0)) > 1 + val diagrams: List, + val images: List, + val showList: Boolean = (diagrams.count() + images.count()) > 1 ) diff --git a/src/main/kotlin/nl/avisi/structurizr/site/generatr/site/model/SoftwareSystemContainerComponentCodePageViewModel.kt b/src/main/kotlin/nl/avisi/structurizr/site/generatr/site/model/SoftwareSystemContainerComponentCodePageViewModel.kt index 27be06f8..90993524 100644 --- a/src/main/kotlin/nl/avisi/structurizr/site/generatr/site/model/SoftwareSystemContainerComponentCodePageViewModel.kt +++ b/src/main/kotlin/nl/avisi/structurizr/site/generatr/site/model/SoftwareSystemContainerComponentCodePageViewModel.kt @@ -17,7 +17,7 @@ class SoftwareSystemContainerComponentCodePageViewModel(generatorContext: Genera val containerTabs = createContainersCodeTabViewModel(generatorContext, container.softwareSystem) val componentTabs = createComponentsTabViewModel(generatorContext, container) val diagramIndexListViewModel = DiagramIndexListViewModel( - null, + emptyList(), images ) companion object { diff --git a/src/main/kotlin/nl/avisi/structurizr/site/generatr/site/model/SoftwareSystemContextPageViewModel.kt b/src/main/kotlin/nl/avisi/structurizr/site/generatr/site/model/SoftwareSystemContextPageViewModel.kt index 7fcf58e8..f03b1ffd 100644 --- a/src/main/kotlin/nl/avisi/structurizr/site/generatr/site/model/SoftwareSystemContextPageViewModel.kt +++ b/src/main/kotlin/nl/avisi/structurizr/site/generatr/site/model/SoftwareSystemContextPageViewModel.kt @@ -13,6 +13,6 @@ class SoftwareSystemContextPageViewModel(generatorContext: GeneratorContext, sof val visible = generatorContext.workspace.views.hasSystemContextViews(softwareSystem) val diagramIndexListViewModel = DiagramIndexListViewModel( diagrams, - null + emptyList() ) } diff --git a/src/main/kotlin/nl/avisi/structurizr/site/generatr/site/model/SoftwareSystemDeploymentPageViewModel.kt b/src/main/kotlin/nl/avisi/structurizr/site/generatr/site/model/SoftwareSystemDeploymentPageViewModel.kt index 443552e5..7efd36ad 100644 --- a/src/main/kotlin/nl/avisi/structurizr/site/generatr/site/model/SoftwareSystemDeploymentPageViewModel.kt +++ b/src/main/kotlin/nl/avisi/structurizr/site/generatr/site/model/SoftwareSystemDeploymentPageViewModel.kt @@ -13,6 +13,6 @@ class SoftwareSystemDeploymentPageViewModel(generatorContext: GeneratorContext, val visible = generatorContext.workspace.views.hasDeploymentViews(softwareSystem) val diagramIndexListViewModel = DiagramIndexListViewModel( diagrams, - null + emptyList() ) } diff --git a/src/main/kotlin/nl/avisi/structurizr/site/generatr/site/model/SoftwareSystemDynamicPageViewModel.kt b/src/main/kotlin/nl/avisi/structurizr/site/generatr/site/model/SoftwareSystemDynamicPageViewModel.kt index 8c9d5195..c7fa348e 100644 --- a/src/main/kotlin/nl/avisi/structurizr/site/generatr/site/model/SoftwareSystemDynamicPageViewModel.kt +++ b/src/main/kotlin/nl/avisi/structurizr/site/generatr/site/model/SoftwareSystemDynamicPageViewModel.kt @@ -13,6 +13,6 @@ class SoftwareSystemDynamicPageViewModel(generatorContext: GeneratorContext, sof val visible = generatorContext.workspace.views.hasDynamicViews(softwareSystem) val diagramIndexListViewModel = DiagramIndexListViewModel( diagrams, - null + emptyList() ) }