Fix coroutine scope (#4820)

* Inject the session scope instead of the application scope where it's possible.

* Create AppCoroutineScope annotation to let developers explicitly choose the appropriate CoroutineScope when injecting one.
This commit is contained in:
Benoit Marty 2025-06-04 17:33:51 +02:00 committed by GitHub
parent 88124cd770
commit 03e23477b7
58 changed files with 172 additions and 72 deletions

View file

@ -0,0 +1,18 @@
/*
* Copyright 2024 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.di.annotations
import javax.inject.Qualifier
/**
* Qualifies a [CoroutineScope] object which represents the base coroutine scope to use for the application.
*/
@Retention(AnnotationRetention.RUNTIME)
@MustBeDocumented
@Qualifier
annotation class AppCoroutineScope