randydev commited on
Commit
7660a71
·
verified ·
1 Parent(s): 4e4d872

Update config.js

Browse files
Files changed (1) hide show
  1. config.js +8 -1
config.js CHANGED
@@ -6,8 +6,15 @@ const dbUri = process.env.DB_URI;
6
  const HUGGING_TOKEN = process.env.HUGGING_TOKEN;
7
  const GoogleAPIKey = process.env.GOOGLE_API_KEY;
8
  const BotToken = process.env.BOT_TOKEN;
 
9
 
10
- if (!dbUri && !HUGGING_TOKEN && !GoogleAPIKey && !BotToken) {
 
 
 
 
 
 
11
  throw new Error("Missing variables required");
12
  }
13
 
 
6
  const HUGGING_TOKEN = process.env.HUGGING_TOKEN;
7
  const GoogleAPIKey = process.env.GOOGLE_API_KEY;
8
  const BotToken = process.env.BOT_TOKEN;
9
+ const IsTelegramBot = false;
10
 
11
+ if (IsTelegramBot) {
12
+ if(!BotToken) {
13
+ throw new Error("Required `BOT_TOKEN` ");
14
+ }
15
+ }
16
+
17
+ if (!dbUri && !HUGGING_TOKEN && !GoogleAPIKey) {
18
  throw new Error("Missing variables required");
19
  }
20