Skip to content

Commit

Permalink
fix: Making sure email setting model opens when emailSettingsModal.op…
Browse files Browse the repository at this point in the history
…en is true
  • Loading branch information
zwidekalanga committed Jul 31, 2024
1 parent 01ceb41 commit cb44d5d
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@ const BaseCourseCard = ({

const handleEmailSettingsModalOnClose = (newValue) => {
resetModals();
if (hasEmailsEnabled !== undefined) {
if (newValue !== undefined) {
setHasEmailsEnabled(newValue);
}
};
Expand Down Expand Up @@ -345,6 +345,7 @@ const BaseCourseCard = ({
if (!hasEmailsEnabled) {
return null;
}

return (
<EmailSettingsModal
{...emailSettingsModal.options}
Expand Down

0 comments on commit cb44d5d

Please sign in to comment.