Skip to content

Commit

Permalink
Merge pull request #540 from mozilla/holiday-promo-news
Browse files Browse the repository at this point in the history
MPP-3589 - Show news item to free users
  • Loading branch information
lloan committed Nov 23, 2023
2 parents b038cdc + c73076a commit f53b49d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/js/popup/popup.js
Original file line number Diff line number Diff line change
Expand Up @@ -1744,8 +1744,8 @@
const holidayPromoExpires = new Date('2023-11-31');
const isHolidayPromo2023Active = currentDate <= holidayPromoExpires;

// Show if promo is available, if active and if premium is availble in user's region
if (isHolidayPromo2023Available && isHolidayPromo2023Active && premiumAvailability) {
// Show if promo is available, if user does not have premium, if active and if premium is availble in user's region
if (isHolidayPromo2023Available && !premium && isHolidayPromo2023Active && premiumAvailability) {
const getPeriodicalPremiumPlanYearlyId = getPeriodicalPremiumPlans.plan_country_lang_mapping[getPeriodicalPremiumPlans.country_code]["*"].yearly.id;
const fxaOrigin = (await browser.storage.local.get("fxaOrigin")).fxaOrigin.FXA_ORIGIN;
const holidayPromo2023Url = `${fxaOrigin}/subscriptions/products/${getPeriodicalPremiumProductId}?plan=${getPeriodicalPremiumPlanYearlyId}&coupon=HOLIDAY20`;
Expand Down

0 comments on commit f53b49d

Please sign in to comment.