Open-source, secure environment with real-world tools for enterprise-grade agents.
Python agentaiai-agentai-agentscode-interpretercopilotdevelopmentdevtoolsgptgpt-4javascriptllmnextjsopenaipythonreactsoftwaretypescript
Fix authErrorBox switch breaking (#734)
Ben Fornefelda1c246684195
diff --git a/.changeset/tasty-lemons-grow.md b/.changeset/tasty-lemons-grow.mdnew file mode 100644index 000000000..d9d8c0855--- /dev/null+++ b/.changeset/tasty-lemons-grow.md@@ -0,0 +1,5 @@+---+'@e2b/cli': minor+---++fix determining the correct auth error messagediff --git a/packages/cli/src/api.ts b/packages/cli/src/api.tsindex ca5deb12c..027677d28 100644--- a/packages/cli/src/api.ts+++ b/packages/cli/src/api.ts@@ -14,10 +14,11 @@ const authErrorBox = (keyName: string) => {case 'E2B_API_KEY':link = 'https://e2b.dev/dashboard?tab=keys'msg = 'API key'-+ breakcase 'E2B_ACCESS_TOKEN':link = 'https://e2b.dev/dashboard?tab=personal'msg = 'access token'+ break}// throwing error in default in switch statement results in unreachable code,// so we need to check if link and msg are defined here instead