diff --git a/client/src/document/organisms/toc/index.tsx b/client/src/document/organisms/toc/index.tsx index 2e36be93dbfb..99d4fdd20086 100644 --- a/client/src/document/organisms/toc/index.tsx +++ b/client/src/document/organisms/toc/index.tsx @@ -48,7 +48,7 @@ export function TOC({ toc, title }: { toc: Toc[]; title?: string }) { }, [observedElements, referencedIds]); useFirstVisibleElement(observedElements, (element: Element | null) => { - const id = element ? idByObservedElement.current.get(element) ?? "" : ""; + const id = element ? (idByObservedElement.current.get(element) ?? "") : ""; if (id !== currentViewedTocItem) { setCurrentViewedTocItem(id); } diff --git a/client/src/user-context.tsx b/client/src/user-context.tsx index e3556d2884cc..d59b371995c2 100644 --- a/client/src/user-context.tsx +++ b/client/src/user-context.tsx @@ -218,7 +218,7 @@ export function UserDataProvider(props: { children: React.ReactNode }) { subscriptionType: data.subscription_type === "core" ? SubscriptionType.MDN_CORE - : data.subscription_type ?? null, + : (data.subscription_type ?? null), subscriberNumber: data.subscriber_number || null, email: data.email || null, geo: { diff --git a/cloud-function/src/headers.ts b/cloud-function/src/headers.ts index 9deeebc3fa95..e595fc448226 100644 --- a/cloud-function/src/headers.ts +++ b/cloud-function/src/headers.ts @@ -81,7 +81,7 @@ function getCacheMaxAgeForUrl(url: string): number { } function parseContentType(value: unknown): string { - const firstValue = Array.isArray(value) ? value[0] ?? "" : value; + const firstValue = Array.isArray(value) ? (value[0] ?? "") : value; return typeof firstValue === "string" ? firstValue : ""; } diff --git a/package.json b/package.json index e0e085a8f7a4..247d2c15bf11 100644 --- a/package.json +++ b/package.json @@ -221,7 +221,7 @@ "postcss-loader": "^8.1.1", "postcss-normalize": "^10.0.1", "postcss-preset-env": "^9.6.0", - "prettier": "^3.3.2", + "prettier": "^3.3.3", "prettier-plugin-packagejson": "^2.5.1", "prompts": "^2.4.2", "react": "^18.3.1", diff --git a/yarn.lock b/yarn.lock index fdbb86d65319..8ec0897720ae 100644 --- a/yarn.lock +++ b/yarn.lock @@ -12868,10 +12868,10 @@ prettier-plugin-packagejson@^2.5.1: sort-package-json "2.10.0" synckit "0.9.1" -prettier@^3.3.2: - version "3.3.2" - resolved "https://registry.yarnpkg.com/prettier/-/prettier-3.3.2.tgz#03ff86dc7c835f2d2559ee76876a3914cec4a90a" - integrity sha512-rAVeHYMcv8ATV5d508CFdn+8/pHPpXeIid1DdrPwXnaAdH7cqjVbpJaT5eq4yRAFU/lsbwYwSF/n5iNrdJHPQA== +prettier@^3.3.3: + version "3.3.3" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-3.3.3.tgz#30c54fe0be0d8d12e6ae61dbb10109ea00d53105" + integrity sha512-i2tDNA0O5IrMO757lfrdQZCc2jPNDVntV0m/+4whiDfWaTKfMNgR7Qz0NAeGz/nRqF4m5/6CLzbP4/liHt12Ew== pretty-error@^4.0.0: version "4.0.0"