Fixed issue with groups timeline composer sticking to group when leaving page

• Fixed:
- issue with groups timeline composer sticking to group when leaving page
This commit is contained in:
mgabdev 2020-12-24 13:18:54 -05:00
parent 47dbe64df1
commit 0ceccce04a
1 changed files with 6 additions and 0 deletions

View File

@ -5,6 +5,7 @@ import { defineMessages, injectIntl } from 'react-intl'
import ImmutablePropTypes from 'react-immutable-proptypes'
import ImmutablePureComponent from 'react-immutable-pure-component'
import { fetchGroup } from '../actions/groups'
import { changeComposeGroupId } from '../actions/compose'
import PageTitle from '../features/ui/util/page_title'
import GroupLayout from '../layouts/group_layout'
import TimelineComposeBlock from '../components/timeline_compose_block'
@ -18,6 +19,11 @@ class GroupPage extends ImmutablePureComponent {
this.props.dispatch(fetchGroup(this.props.params.id))
}
componentWillUnmount() {
//Reset group composer
this.props.dispatch(changeComposeGroupId(null))
}
render() {
const {
intl,