From 3b6cd7a3851663a05e53f35dc24fbfe669685f2a Mon Sep 17 00:00:00 2001 From: Username404 Date: Mon, 7 Jun 2021 22:00:28 +0200 Subject: [PATCH] Shorten the EventSnowy.Companion.useKey() method --- common/src/main/kotlin/fr/username404/snowygui/EventSnowy.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/src/main/kotlin/fr/username404/snowygui/EventSnowy.kt b/common/src/main/kotlin/fr/username404/snowygui/EventSnowy.kt index 30f3b46..d82aca6 100644 --- a/common/src/main/kotlin/fr/username404/snowygui/EventSnowy.kt +++ b/common/src/main/kotlin/fr/username404/snowygui/EventSnowy.kt @@ -8,7 +8,7 @@ interface EventSnowy { } } companion object { - fun useKey(key: String): MutableSet { return eventMap.getOrPut(key, ::mutableSetOf) } + fun useKey(key: String): MutableSet = eventMap.getOrPut(key, ::mutableSetOf) private val eventMap: MutableMap> = mutableMapOf() } }