Skip to content

Commit

Permalink
Fix NewsPopup close button when showInSidebar=true
Browse files Browse the repository at this point in the history
  • Loading branch information
manisandro committed Dec 14, 2024
1 parent 4db1de6 commit 70e55cf
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion plugins/NewsPopup.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,11 @@ class NewsPopup extends React.Component {
d.setTime(d.getTime() + (days * 24 * 60 * 60 * 1000));
document.cookie = "newsrev=" + this.props.newsRev + "; SameSite=Lax; expires=" + d.toUTCString();
}
this.setState({showPopup: false});
if (this.props.showInSidebar) {
this.props.setCurrentTask(null);
} else {
this.setState({showPopup: false});
}
};
}

Expand Down

0 comments on commit 70e55cf

Please sign in to comment.