diff options
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/utils/ConditionalUtils.kt')
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/utils/ConditionalUtils.kt | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/utils/ConditionalUtils.kt b/src/main/java/at/hannibal2/skyhanni/utils/ConditionalUtils.kt index 1ee91774b..00aec1dc5 100644 --- a/src/main/java/at/hannibal2/skyhanni/utils/ConditionalUtils.kt +++ b/src/main/java/at/hannibal2/skyhanni/utils/ConditionalUtils.kt @@ -5,8 +5,8 @@ import io.github.notenoughupdates.moulconfig.observer.Property object ConditionalUtils { - fun <T> T.transformIf(condition: T.() -> Boolean, transofmration: T.() -> T) = - if (condition()) transofmration(this) else this + fun <T> T.transformIf(condition: T.() -> Boolean, transformation: T.() -> T) = + if (condition()) transformation(this) else this fun <T> T.conditionalTransform(condition: Boolean, ifTrue: T.() -> Any, ifFalse: T.() -> Any) = if (condition) ifTrue(this) else ifFalse(this) |