Disable creating polls within threads (#7914)

This commit is contained in:
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

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"