Merged in chore/remove-unused-env-vars (pull request #2463)

chore: Remove unused env vars and feature toggles

* Remove unused env vars and feature toggles


Approved-by: Joakim Jäderberg
This commit is contained in:
Anton Gunnarsson
2025-06-30 07:48:05 +00:00
parent bdf66af23d
commit f0def99425
38 changed files with 28 additions and 369 deletions

View File

@@ -3,7 +3,6 @@ import { cache } from "react"
import * as routes from "@scandic-hotels/common/constants/routes/myPages"
import { safeTry } from "@scandic-hotels/common/utils/safeTry"
import { env } from "../../../../env/server"
import { getEurobonusMembership } from "../../user/helpers"
import type { Lang } from "@scandic-hotels/common/constants/language"
@@ -67,9 +66,7 @@ export const getPrimaryLinks = cache(
const isScandicXSASActive = (loyalty: UserLoyalty) => {
const eurobonusMembership = getEurobonusMembership(loyalty)
const isLinked = Boolean(eurobonusMembership)
return env.SAS_ENABLED && isLinked
return Boolean(eurobonusMembership)
}
const showTeamMemberCard = cache(async () => {

View File

@@ -2,7 +2,6 @@ import { myStay } from "@scandic-hotels/common/constants/routes/myStay"
import { dt } from "@scandic-hotels/common/dt"
import { createCounter } from "@scandic-hotels/common/telemetry"
import * as maskValue from "@scandic-hotels/common/utils/maskValue"
import { getCurrentWebUrl } from "@scandic-hotels/common/utils/url"
import { env } from "../../../env/server"
import * as api from "../../api"
@@ -340,15 +339,7 @@ export async function updateStaysBookingUrl(
const baseUrl = env.PUBLIC_URL || "https://www.scandichotels.com"
// Construct Booking URL.
const bookingUrl = !env.isLangLive(lang)
? new URL(
getCurrentWebUrl({
path: myBookingPath[lang],
lang,
baseUrl,
})
)
: new URL(myStay[lang], baseUrl)
const bookingUrl = new URL(myStay[lang], baseUrl)
// Add search parameters.
if (encryptedBookingValue) {