Disable creating polls within threads (#7914)

pull/21833/head
Michael Telatynski 2022-02-28 15:34:30 +00:00 committed by GitHub
parent 7e4b856ec3
commit 5f8441216c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -337,6 +337,9 @@ class PollButton extends React.PureComponent<IPollButtonProps> {
};
render() {
// do not allow sending polls within threads at this time
if (this.props.relation?.rel_type === RelationType.Thread) return null;
return (
<CollapsibleButton
className="mx_MessageComposer_button mx_MessageComposer_poll"