Skip to content

Commit

Permalink
Wait for the next tick to ensure that the unread indicator is set to …
Browse files Browse the repository at this point in the history
…0 in the SignInPage component
  • Loading branch information
HorusGoul committed Jul 27, 2021
1 parent 79d8bd2 commit 62bf8f5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/pages/signin/SignInPage.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,8 @@ const defaultProps = {
class SignInPage extends Component {
componentDidMount() {
// Always reset the unread counter to zero on this page
updateUnread(0);
// NOTE: We need to wait for the next tick to ensure that the unread indicator is updated
setTimeout(() => updateUnread(0), 0);
}

render() {
Expand Down

0 comments on commit 62bf8f5

Please sign in to comment.