From 489f9f0fd556f795e86b6fc10eba6ff745867efa Mon Sep 17 00:00:00 2001 From: sowjanyakch Date: Mon, 18 Nov 2024 18:54:38 +0100 Subject: [PATCH] write logs for exceptions in viewModel Signed-off-by: sowjanyakch --- .../conversationinfo/viewmodel/ConversationInfoViewModel.kt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/src/main/java/com/nextcloud/talk/conversationinfo/viewmodel/ConversationInfoViewModel.kt b/app/src/main/java/com/nextcloud/talk/conversationinfo/viewmodel/ConversationInfoViewModel.kt index c6cb13fa15..01270ddac9 100644 --- a/app/src/main/java/com/nextcloud/talk/conversationinfo/viewmodel/ConversationInfoViewModel.kt +++ b/app/src/main/java/com/nextcloud/talk/conversationinfo/viewmodel/ConversationInfoViewModel.kt @@ -147,6 +147,7 @@ class ConversationInfoViewModel @Inject constructor( _getTalkBanState.value = ListBansSuccessState(listBans) } catch (exception: Exception) { _getTalkBanState.value = ListBansErrorState + Log.e(TAG, "Error while getting list of banned participants", exception) } } } @@ -165,6 +166,7 @@ class ConversationInfoViewModel @Inject constructor( _getBanActorState.value = BanActorSuccessState(talkBan) } catch (exception: Exception) { _getBanActorState.value = BanActorErrorState + Log.e(TAG, "Error banning a participant", exception) } } } @@ -201,6 +203,7 @@ class ConversationInfoViewModel @Inject constructor( _getUnBanActorState.value = UnBanActorSuccessState } catch (exception: Exception) { _getUnBanActorState.value = UnBanActorErrorState + Log.e(TAG, "Error while unbanning a participant", exception) } } }