Skip to content

Commit

Permalink
fix: ensure codes confirmation modal closes on course about page route (
Browse files Browse the repository at this point in the history
  • Loading branch information
adamstankiewicz authored Jul 22, 2024
1 parent a9026e3 commit 6d1860b
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,10 @@ const ToEcomBasketPage = ({ enrollLabel, enrollmentUrl, courseRunPrice }) => {
optimizelyHandler(e);
};

const handleModalClose = () => {
setIsModalOpen(false);
};

return (
<>
<EnrollButtonCta
Expand All @@ -53,7 +57,7 @@ const ToEcomBasketPage = ({ enrollLabel, enrollmentUrl, courseRunPrice }) => {
/>
<EnrollModal
isModalOpen={isModalOpen}
setIsModalOpen={setIsModalOpen}
onClose={handleModalClose}
enrollmentUrl={enrollmentUrl}
courseRunPrice={courseRunPrice}
userSubsidyApplicableToCourse={userSubsidyApplicableToCourse}
Expand Down

0 comments on commit 6d1860b

Please sign in to comment.