Merge pull request #1341 from coralproject/fix-zen-mode

Fix zen mode
This commit is contained in:
Kim Gardner
2018-02-02 10:00:46 -05:00
committed by GitHub
@@ -397,6 +397,13 @@ class ModerationQueue extends React.Component {
const index = comments.findIndex(
comment => comment.id === selectedCommentId
);
// This can happen temporarily when we call redux to change the selected comment
// but it didn't fully take effect yet.
if (index === -1) {
return null;
}
const comment = comments[index];
return (
<div className={styles.root}>