Fix some Kotlin compiler warnings
[Sone.git] / src / main / kotlin / net / pterodactylus / sone / web / ajax / GetStatusAjaxPage.kt
index 9872d1e..853fe26 100644 (file)
@@ -30,7 +30,7 @@ class GetStatusAjaxPage(webInterface: WebInterface, private val elementLoader: E
        }
 
        override fun createJsonObject(request: FreenetRequest) =
-                       (webInterface.getCurrentSoneWithoutCreatingSession(request.toadletContext) as Sone?).let { currentSone ->
+                       webInterface.getCurrentSoneWithoutCreatingSession(request.toadletContext).let { currentSone ->
                                createSuccessJsonObject().apply {
                                        this["loggedIn"] = currentSone != null
                                        this["options"] = currentSone?.options?.toJsonOptions() ?: jsonObject {}