diff --git a/docs/src/components/InstallBlock/index.js b/docs/src/components/InstallBlock/index.js index ec91c8e7d..24c9a9673 100644 --- a/docs/src/components/InstallBlock/index.js +++ b/docs/src/components/InstallBlock/index.js @@ -6,11 +6,10 @@ export default function InstallBlock() { return ( Loading...}> {() => { - if (window.posthog && typeof window.posthog.get_distinct_id === "function") { - const distinct_id = window.posthog.get_distinct_id() - } else { - const distinct_id = "posthog-blocked" - } + const distinct_id = + (window.posthog && typeof window.posthog.get_distinct_id === "function") + ? window.posthog.get_distinct_id() + : "posthog-blocked" return (