Skip to content
This repository has been archived by the owner on Oct 30, 2024. It is now read-only.

Allow for GOOGLE_AUTH_KEY to be unset when running docs locally #909

Merged
merged 1 commit into from
Jul 25, 2024

Conversation

jerelmiller
Copy link
Member

I'm not entirely convinced this is the right solution, but at least this should provide some discussion. When I try and run docs locally, I'm unable to when it tries to run the algolia script because it tries running .replace on a string that is undefined. The undefined string is due to the GOOGLE_AUTH_KEY environment variable not set, so the app is unable to start.

This PR adds optional chaining to allow for that value to be unset so we can at least startup the client locally without it. Please let me know if you think of a better way to handle this! I'm not sure if this would cause silent errors or not.

@jerelmiller jerelmiller requested a review from a team as a code owner July 15, 2024 17:45
Copy link

netlify bot commented Jul 15, 2024

Deploy Preview for apollo-monodocs failed.

Name Link
🔨 Latest commit c34ea18
🔍 Latest deploy log https://app.netlify.com/sites/apollo-monodocs/deploys/66a28cf92243090008607b0a

@jerelmiller jerelmiller merged commit 1d3216a into main Jul 25, 2024
4 of 9 checks passed
@jerelmiller jerelmiller deleted the jerel/loosen-analytics-key branch July 25, 2024 17:37
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants