aboutsummaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'plugins')
-rw-r--r--plugins/base/src/main/kotlin/transformers/documentables/EmptyPackagesFilterTransformer.kt2
-rw-r--r--plugins/base/src/main/kotlin/transformers/documentables/SuppressedDocumentableFilterTransformer.kt4
2 files changed, 3 insertions, 3 deletions
diff --git a/plugins/base/src/main/kotlin/transformers/documentables/EmptyPackagesFilterTransformer.kt b/plugins/base/src/main/kotlin/transformers/documentables/EmptyPackagesFilterTransformer.kt
index c901c9aa..81d03e27 100644
--- a/plugins/base/src/main/kotlin/transformers/documentables/EmptyPackagesFilterTransformer.kt
+++ b/plugins/base/src/main/kotlin/transformers/documentables/EmptyPackagesFilterTransformer.kt
@@ -7,7 +7,7 @@ import org.jetbrains.dokka.transformers.documentation.sourceSet
class EmptyPackagesFilterTransformer(val context: DokkaContext) : PreMergeDocumentableTransformer {
override fun invoke(modules: List<DModule>): List<DModule> {
- return modules.mapNotNull { module -> filterModule(module) }
+ return modules.mapNotNull(::filterModule)
}
private fun filterModule(module: DModule): DModule? {
diff --git a/plugins/base/src/main/kotlin/transformers/documentables/SuppressedDocumentableFilterTransformer.kt b/plugins/base/src/main/kotlin/transformers/documentables/SuppressedDocumentableFilterTransformer.kt
index 5a2818c7..79feb832 100644
--- a/plugins/base/src/main/kotlin/transformers/documentables/SuppressedDocumentableFilterTransformer.kt
+++ b/plugins/base/src/main/kotlin/transformers/documentables/SuppressedDocumentableFilterTransformer.kt
@@ -10,7 +10,7 @@ import java.io.File
class SuppressedDocumentableFilterTransformer(val context: DokkaContext) : PreMergeDocumentableTransformer {
override fun invoke(modules: List<DModule>): List<DModule> {
- return modules.mapNotNull { module -> filterModule(module) }
+ return modules.mapNotNull(::filterModule)
}
private fun filterModule(module: DModule): DModule? {
@@ -28,7 +28,7 @@ class SuppressedDocumentableFilterTransformer(val context: DokkaContext) : PreMe
return null
}
- val filteredChildren = pkg.children.filter { child -> !isSuppressed(child) }
+ val filteredChildren = pkg.children.filterNot(::isSuppressed)
return when {
filteredChildren == pkg.children -> pkg
filteredChildren.isEmpty() -> null