Fix small code smell (#7058)

* RolesAndPermissionsNode does not need to implement RolesAndPermissionsNavigator and simplify the code.

* Remove default implementation in `RoomMemberListNavigator`

* Remove dead code.

* Fix test compilation issue
This commit is contained in:
Benoit Marty
2026-06-19 15:33:01 +02:00
committed by GitHub
parent e370b33771
commit d4aa49f3d3
7 changed files with 20 additions and 37 deletions
@@ -1,20 +0,0 @@
/*
* Copyright (c) 2025 Element Creations Ltd.
* Copyright 2023-2025 New Vector Ltd.
*
* SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial.
* Please see LICENSE files in the repository root for full details.
*/
package io.element.android.libraries.pushproviders.unifiedpush
import dev.zacsweers.metro.AppScope
import dev.zacsweers.metro.ContributesBinding
interface GuardServiceStarter {
fun start() {}
fun stop() {}
}
@ContributesBinding(AppScope::class)
class NoopGuardServiceStarter : GuardServiceStarter
@@ -31,7 +31,6 @@ private val loggerTag = LoggerTag("VectorUnifiedPushMessagingReceiver", LoggerTa
class VectorUnifiedPushMessagingReceiver : MessagingReceiver() {
@Inject lateinit var pushParser: UnifiedPushParser
@Inject lateinit var pushHandler: PushHandler
@Inject lateinit var guardServiceStarter: GuardServiceStarter
@Inject lateinit var unifiedPushStore: UnifiedPushStore
@Inject lateinit var unifiedPushGatewayResolver: UnifiedPushGatewayResolver
@Inject lateinit var unifiedPushGatewayUrlResolver: UnifiedPushGatewayUrlResolver
@@ -112,7 +111,6 @@ class VectorUnifiedPushMessagingReceiver : MessagingReceiver() {
)
)
}
guardServiceStarter.stop()
}
/**
@@ -266,7 +266,6 @@ class VectorUnifiedPushMessagingReceiverTest : RobolectricTest() {
return VectorUnifiedPushMessagingReceiver().apply {
this.pushParser = unifiedPushParser
this.pushHandler = pushHandler
this.guardServiceStarter = NoopGuardServiceStarter()
this.unifiedPushStore = unifiedPushStore
this.unifiedPushGatewayResolver = unifiedPushGatewayResolver
this.unifiedPushGatewayUrlResolver = unifiedPushGatewayUrlResolver