We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e3588fa commit 5c39bcdCopy full SHA for 5c39bcd
template/app/src/demo-ai-app/operations.ts
@@ -14,8 +14,8 @@ import OpenAI from 'openai';
14
import { SubscriptionStatus } from '../payment/plans';
15
import { ensureArgsSchemaOrThrowHttpError } from '../server/validation';
16
17
-const openAi = getOpenAi();
18
-function getOpenAi(): OpenAI {
+const openAi = setUpOpenAi();
+function setUpOpenAi(): OpenAI {
19
if (process.env.OPENAI_API_KEY) {
20
return new OpenAI({ apiKey: process.env.OPENAI_API_KEY });
21
} else {
0 commit comments