Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ fun NewGroupConversationSearchPeopleScreen(
}

BackHandler(true, onBackClicked)
val isSelfTeamMember = newConversationViewModel.newGroupState.isSelfTeamMember ?: false

val screenTitle = if (newConversationViewModel.newGroupState.isChannel) {
stringResource(id = R.string.label_new_channel)
Expand All @@ -61,7 +60,7 @@ fun NewGroupConversationSearchPeopleScreen(
OtherUserProfileScreenDestination(QualifiedID(contact.id, contact.domain))
.let { navigator.navigate(NavigationCommand(it)) }
},
shouldShowChannelPromotion = !isSelfTeamMember,
shouldShowChannelPromotion = false,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

don't we need to remove the whole core to shouldShowChannelPromotion ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I did not want to do it since this is a temporary fix and we will revert it.

isUserAllowedToCreateChannels = false,
onContactChecked = newConversationViewModel::updateSelectedContacts,
onContinue = { navigator.navigate(NavigationCommand(NewGroupNameScreenDestination)) },
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,12 +45,10 @@ fun NewConversationSearchPeopleScreen(
navigator: Navigator,
newConversationViewModel: NewConversationViewModel,
) {
val isSelfTeamMember = newConversationViewModel.newGroupState.isSelfTeamMember ?: false
val shouldShowChannelPromotion = !isSelfTeamMember
val showCreateTeamDialog = remember { mutableStateOf(false) }
SearchUsersAndAppsScreen(
searchTitle = stringResource(id = R.string.label_new_conversation),
shouldShowChannelPromotion = shouldShowChannelPromotion,
shouldShowChannelPromotion = false,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same here

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I did not want to do it since this is a temporary fix and we will revert it.

isUserAllowedToCreateChannels = newConversationViewModel.isChannelCreationPossible,
onOpenUserProfile = { contact ->
OtherUserProfileScreenDestination(QualifiedID(contact.id, contact.domain))
Expand All @@ -62,12 +60,8 @@ fun NewConversationSearchPeopleScreen(
navigator.navigate(NavigationCommand(NewGroupConversationSearchPeopleScreenDestination))
},
onCreateNewChannel = {
if (!shouldShowChannelPromotion) {
newConversationViewModel.setIsChannel(true)
navigator.navigate(NavigationCommand(NewGroupConversationSearchPeopleScreenDestination))
} else {
showCreateTeamDialog.value = true
}
newConversationViewModel.setIsChannel(true)
navigator.navigate(NavigationCommand(NewGroupConversationSearchPeopleScreenDestination))
},
isGroupSubmitVisible = newConversationViewModel.newGroupState.isGroupCreatingAllowed == true,
onClose = navigator::navigateBack,
Expand Down