Skip to content

Commit

Permalink
fix: hide Order History from the MFE user menu when it isn't configur…
Browse files Browse the repository at this point in the history
…ed (#161)
  • Loading branch information
umarmughal824 authored Sep 13, 2021
1 parent 562a7bf commit b57ce40
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/Header.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -107,10 +107,11 @@ function Header({ intl }) {
];

// Users should only see Order History if they do not have an available
// learner portal, because an available learner portal currently means
// learner portal and have a ORDER_HISTORY_URL define in the environment,
// because an available learner portal currently means
// that they access content via Subscriptions, in which context an "order"
// is not relevant.
if (!enterpriseLearnerPortalLink) {
if (!enterpriseLearnerPortalLink && config.ORDER_HISTORY_URL) {
userMenu.splice(-1, 0, orderHistoryItem);
}

Expand Down

0 comments on commit b57ce40

Please sign in to comment.