From d173bdf8e20878515422ce4e4ae84586ef59c4b2 Mon Sep 17 00:00:00 2001 From: M Fahru Date: Tue, 3 Jun 2025 06:41:33 -0700 Subject: [PATCH] Merge pull request #25355 from overleaf/mf-whitelist-staging-url-stripe-test [web] Bypass country requirement for Stripe if user is on staging or dev environment to ease the testing process GitOrigin-RevId: 0924a57d3a1b7b530a3822fb8f9056a1dd7119e9 --- .../src/Features/Subscription/SubscriptionController.js | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/services/web/app/src/Features/Subscription/SubscriptionController.js b/services/web/app/src/Features/Subscription/SubscriptionController.js index 4a69acf56d..4be61d255c 100644 --- a/services/web/app/src/Features/Subscription/SubscriptionController.js +++ b/services/web/app/src/Features/Subscription/SubscriptionController.js @@ -704,7 +704,7 @@ async function getRecommendedCurrency(req, res) { ip = req.query.ip } const currencyLookup = await GeoIpLookup.promises.getCurrencyCode(ip) - let countryCode = currencyLookup.countryCode + const countryCode = currencyLookup.countryCode const recommendedCurrency = currencyLookup.currencyCode let currency = null @@ -715,13 +715,6 @@ async function getRecommendedCurrency(req, res) { currency = recommendedCurrency } - const queryCountryCode = req.query.countryCode?.toUpperCase() - - // only enable countryCode testing flag on staging or dev environments - if (queryCountryCode && process.env.NODE_ENV !== 'production') { - countryCode = queryCountryCode - } - return { currency, recommendedCurrency,