feat(profiles): add local on-device profile hiding and filtering
This commit is contained in:
1 parent
5c8ab7ed6c
commit
cdcecb9734
11 files changed
+240
-10
No files matched your search
@@ -1901,7 +1901,10 @@ class ChatViewModel(
|
||||
// Fetch available bot profiles for @ autocomplete
|
||||
val profilesResult = safeApiCall { ApiClient.hermesApi.getProfiles() }
|
||||
if (profilesResult is NetworkResult.Success) {
|
||||
val profiles = profilesResult.data.profiles.orEmpty()
|
||||
val profiles =
|
||||
profilesResult.data.profiles.orEmpty().filter {
|
||||
!AuthManager.isProfileHidden(it.name) && it.botMeta()?.hidden != true
|
||||
}
|
||||
_uiState.update { it.copy(availableBots = profiles) }
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user