ktlintFormat

Signed-off-by: sowjanyakch <sowjanya.kch@gmail.com>
This commit is contained in:
sowjanyakch 2024-12-19 15:35:43 +01:00 committed by Marcel Hibbe
parent 9068a42f10
commit 298cf3a249
No known key found for this signature in database
GPG Key ID: C793F8B59F43CE7B
3 changed files with 3 additions and 3 deletions

View File

@ -11,5 +11,5 @@ import io.reactivex.Observable
interface OpenConversationsRepository { interface OpenConversationsRepository {
fun fetchConversations(searchTerm:String): Observable<List<Conversation>> fun fetchConversations(searchTerm: String): Observable<List<Conversation>>
} }

View File

@ -21,7 +21,7 @@ class OpenConversationsRepositoryImpl(private val ncApi: NcApi, currentUserProvi
val apiVersion = ApiUtils.getConversationApiVersion(currentUser, intArrayOf(ApiUtils.API_V4, ApiUtils.API_V3, 1)) val apiVersion = ApiUtils.getConversationApiVersion(currentUser, intArrayOf(ApiUtils.API_V4, ApiUtils.API_V3, 1))
override fun fetchConversations(searchTerm:String): Observable<List<Conversation>> { override fun fetchConversations(searchTerm: String): Observable<List<Conversation>> {
val roomOverall = ncApi.getOpenConversations( val roomOverall = ncApi.getOpenConversations(
credentials, credentials,
ApiUtils.getUrlForOpenConversations(apiVersion, currentUser.baseUrl!!), ApiUtils.getUrlForOpenConversations(apiVersion, currentUser.baseUrl!!),

View File

@ -38,7 +38,7 @@ class OpenConversationsViewModel @Inject constructor(private val repository: Ope
fun fetchConversations() { fun fetchConversations() {
_viewState.value = FetchConversationsStartState _viewState.value = FetchConversationsStartState
repository.fetchConversations(_searchTerm.value?: "") repository.fetchConversations(_searchTerm.value ?: "")
.subscribeOn(Schedulers.io()) .subscribeOn(Schedulers.io())
?.observeOn(AndroidSchedulers.mainThread()) ?.observeOn(AndroidSchedulers.mainThread())
?.subscribe(FetchConversationsObserver()) ?.subscribe(FetchConversationsObserver())