Skip to content
Snippets Groups Projects
Unverified Commit 5bfd802c authored by Eugen Rochko's avatar Eugen Rochko Committed by GitHub
Browse files

Fix not being able to directly switch between list timelines in web UI (#10973)

parent 2657765d
Branches
No related tags found
No related merge requests found
......@@ -75,6 +75,23 @@ class ListTimeline extends React.PureComponent {
this.disconnect = dispatch(connectListStream(id));
}
componentWillReceiveProps (nextProps) {
const { dispatch } = this.props;
const { id } = nextProps.params;
if (id !== this.props.params.id) {
if (this.disconnect) {
this.disconnect();
this.disconnect = null;
}
dispatch(fetchList(id));
dispatch(expandListTimeline(id));
this.disconnect = dispatch(connectListStream(id));
}
}
componentWillUnmount () {
if (this.disconnect) {
this.disconnect();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment