mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2026-07-25 06:54:43 +00:00
Removed report button from profile top bar actions for joined groups.
This commit is contained in:
@@ -754,7 +754,8 @@ void TopBar::setupActions(not_null<Window::SessionController*> controller) {
|
||||
buttons.push_back(message);
|
||||
_actions->add(message);
|
||||
}
|
||||
if (!topic && channel && !channel->amIn()) {
|
||||
const auto canJoin = (!topic && channel && !channel->amIn());
|
||||
if (canJoin) {
|
||||
const auto join = Ui::CreateChild<TopBarActionButton>(
|
||||
this,
|
||||
tr::lng_profile_action_short_join(tr::now),
|
||||
@@ -942,6 +943,7 @@ void TopBar::setupActions(not_null<Window::SessionController*> controller) {
|
||||
return;
|
||||
}
|
||||
if (!topic
|
||||
&& canJoin
|
||||
&& ((chat && !chat->amCreator() && !chat->hasAdminRights())
|
||||
|| (channel
|
||||
&& !channel->amCreator()
|
||||
|
||||
Reference in New Issue
Block a user