@rpcbase/server 0.565.0 → 0.567.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -3754,17 +3754,17 @@ class PostHog extends PostHogBackendClient {
3754
3754
  }
3755
3755
  let client;
3756
3756
  let shutdownHookBound = false;
3757
- const resolveApiKey = (env2) => env2.POSTHOG_API_KEY || env2.POSTHOG_KEY || env2.POSTHOG_SERVER_KEY;
3758
- const resolveHost = (env2) => env2.POSTHOG_HOST || env2.RB_POSTHOG_HOST || "https://eu.i.posthog.com";
3757
+ const resolvePosthogApiKey = (env2) => env2.RB_PUBLIC_POSTHOG_KEY;
3758
+ const resolvePosthogHost = () => "https://eu.i.posthog.com";
3759
3759
  const getPosthogClient = (env2) => {
3760
3760
  if (client !== void 0) return client;
3761
- const apiKey = resolveApiKey(env2);
3761
+ const apiKey = resolvePosthogApiKey(env2);
3762
3762
  if (!apiKey) {
3763
3763
  client = null;
3764
3764
  return client;
3765
3765
  }
3766
3766
  client = new PostHog(apiKey, {
3767
- host: resolveHost(env2),
3767
+ host: resolvePosthogHost(),
3768
3768
  enableExceptionAutocapture: true,
3769
3769
  flushAt: 1,
3770
3770
  flushInterval: 1e3