[FIX] Check videoConf type (#4707)

* add videoconf check

* update message type
This commit is contained in:
Gleidson Daniel Silva 2022-11-24 14:24:20 -03:00 committed by GitHub
parent 362df65bbe
commit 21ee25e818
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 2 deletions

View File

@ -353,7 +353,7 @@ const MessageActions = React.memo(
const getOptions = (message: TAnyMessageModel) => { const getOptions = (message: TAnyMessageModel) => {
const options: TActionSheetOptionsItem[] = []; const options: TActionSheetOptionsItem[] = [];
const videoConfBlock = !!(message?.blocks && message?.blocks[0]?.type === 'video_conf'); const videoConfBlock = message.t === 'videoconf';
// Quote // Quote
if (!isReadOnly && !videoConfBlock) { if (!isReadOnly && !videoConfBlock) {

View File

@ -270,7 +270,7 @@ class MessageContainer extends React.Component<IMessageContainerProps, IMessageC
get isInfo(): string | boolean { get isInfo(): string | boolean {
const { item } = this.props; const { item } = this.props;
if (['e2e', 'discussion-created', 'jitsi_call_started'].includes(item.t)) { if (['e2e', 'discussion-created', 'jitsi_call_started', 'videoconf'].includes(item.t)) {
return false; return false;
} }
return item.t; return item.t;

View File

@ -222,6 +222,7 @@ export type MessageTypesValues =
| 'room-allowed-reacting' | 'room-allowed-reacting'
| 'room-disallowed-reacting' | 'room-disallowed-reacting'
| 'command' | 'command'
| 'videoconf'
| LivechatMessageTypes | LivechatMessageTypes
| TeamMessageTypes | TeamMessageTypes
| VoipMessageTypesValues | VoipMessageTypesValues