aboutsummaryrefslogtreecommitdiff
path: root/core/src/main/kotlin/plugability
diff options
context:
space:
mode:
authorSzymon Świstun <sswistun@virtuslab.com>2020-03-04 17:46:19 +0100
committerPaweł Marks <Kordyjan@users.noreply.github.com>2020-03-17 14:38:44 +0100
commitf94bbdc3bfa66bf2d485007739ce19a3befda98c (patch)
tree34b22233849ec7b79d10071ccd7a8417ed12de36 /core/src/main/kotlin/plugability
parent128e3fee4182c0957e266accc99b174815486520 (diff)
downloaddokka-f94bbdc3bfa66bf2d485007739ce19a3befda98c.tar.gz
dokka-f94bbdc3bfa66bf2d485007739ce19a3befda98c.tar.bz2
dokka-f94bbdc3bfa66bf2d485007739ce19a3befda98c.zip
Combine multiple applyIf
Diffstat (limited to 'core/src/main/kotlin/plugability')
-rw-r--r--core/src/main/kotlin/plugability/extensions.kt3
1 files changed, 2 insertions, 1 deletions
diff --git a/core/src/main/kotlin/plugability/extensions.kt b/core/src/main/kotlin/plugability/extensions.kt
index 46c356df..1f994e75 100644
--- a/core/src/main/kotlin/plugability/extensions.kt
+++ b/core/src/main/kotlin/plugability/extensions.kt
@@ -96,7 +96,8 @@ class ExtendingDSL(private val pluginClass: String, private val extensionName: S
ExtensionOrdered(extensionPoint, pluginClass, extensionName, action, block)
infix fun <T : Any> Extension<T>.applyIf(condition: DokkaConfiguration.() -> Boolean): Extension<T> =
- this.setCondition(condition)
+ this.setCondition { this@applyIf.condition(this) && condition(this) }
+
}
@ExtensionsDsl