diff --git a/app/soapbox/features/ui/components/tabs_bar.js b/app/soapbox/features/ui/components/tabs_bar.js index 980ece692..7056093f5 100644 --- a/app/soapbox/features/ui/components/tabs_bar.js +++ b/app/soapbox/features/ui/components/tabs_bar.js @@ -20,7 +20,6 @@ const messages = defineMessages({ post: { id: 'tabs_bar.post', defaultMessage: 'Post' }, }); -@withRouter class TabsBar extends React.PureComponent { static propTypes = { @@ -162,10 +161,6 @@ const mapStateToProps = state => { notificationCount: state.getIn(['notifications', 'unread']), chatsCount: state.get('chats').reduce((acc, curr) => acc + Math.min(curr.get('unread', 0), 1), 0), dashboardCount: reportsCount + approvalCount, - - // HACK: We made things too efficient and now the tabs bar doesn't work right - // ¯\_(ツ)_/¯ - forceRerender: Math.random(), }; }; @@ -178,6 +173,6 @@ const mapDispatchToProps = (dispatch) => ({ }, }); -export default injectIntl( +export default withRouter(injectIntl( connect(mapStateToProps, mapDispatchToProps, null, { forwardRef: true }, - )(TabsBar)); + )(TabsBar)));