diff --git a/src/components/views/rooms/MessageComposerButtons.tsx b/src/components/views/rooms/MessageComposerButtons.tsx index e659fb069f..20c8d05466 100644 --- a/src/components/views/rooms/MessageComposerButtons.tsx +++ b/src/components/views/rooms/MessageComposerButtons.tsx @@ -321,7 +321,7 @@ class PollButton extends React.PureComponent { }, ); } else { - const threadId = this.props.relation.rel_type === RelationType.Thread + const threadId = this.props.relation?.rel_type === RelationType.Thread ? this.props.relation.event_id : null;