From fe5a065f7f84ab92937b5cb5a7978dec16677e09 Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20=E2=80=98Bombe=E2=80=99=20Roden?= Date: Sun, 3 Nov 2019 00:51:08 +0100 Subject: [PATCH] =?utf8?q?=E2=99=BB=EF=B8=8F=20Kotlinize=20expression?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- src/main/kotlin/net/pterodactylus/sone/freenet/wot/IdentityLoader.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/kotlin/net/pterodactylus/sone/freenet/wot/IdentityLoader.kt b/src/main/kotlin/net/pterodactylus/sone/freenet/wot/IdentityLoader.kt index 3fa87ba..b40484e 100644 --- a/src/main/kotlin/net/pterodactylus/sone/freenet/wot/IdentityLoader.kt +++ b/src/main/kotlin/net/pterodactylus/sone/freenet/wot/IdentityLoader.kt @@ -49,7 +49,7 @@ class IdentityLoader @Inject constructor(private val webOfTrustConnector: WebOfT } private fun OwnIdentity.doesNotHaveCorrectContext() = - context != null && !hasContext(context.context) + context?.let { it.context !in contexts } ?: false private fun time(logMessage: (Stopwatch, Collection) -> String, loader: () -> Collection): Collection = Stopwatch.createStarted().let { stopwatch -> -- 2.7.4