Gift Profile Filter: Support for users (#5650)
This commit is contained in:
parent
28419b6354
commit
f8b13f48c2
@ -8,6 +8,7 @@ import {
|
||||
} from '../helpers';
|
||||
import { selectChat } from './chats';
|
||||
import { selectTabState } from './tabs';
|
||||
import { selectUser } from './users';
|
||||
|
||||
export function selectPaymentInputInvoice<T extends GlobalState>(
|
||||
global: T,
|
||||
@ -76,7 +77,8 @@ export function selectCanUseGiftProfileFilter<T extends GlobalState>(
|
||||
global: T, peerId: string,
|
||||
) {
|
||||
const chat = selectChat(global, peerId);
|
||||
return chat && isChatChannel(chat);
|
||||
const user = selectUser(global, peerId);
|
||||
return Boolean(user) || (chat && isChatChannel(chat));
|
||||
}
|
||||
|
||||
export function selectGiftProfileFilter<T extends GlobalState>(
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user