Skip to content

Commit

Permalink
Add comment to config.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
Timothy-Gonzalez committed Nov 3, 2023
1 parent 1943379 commit 187cf7b
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/config.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
/*
* This file defines all config used anywhere in the api. These values need to be defined on import.
*
* By moving all env variable usage to one place, we also make managing their usage much easier, and
* can error if they are not defined.
*/

import env from "./env.js";

export enum Device {
Expand Down Expand Up @@ -45,7 +52,6 @@ const Config = {
METADATA_URL: "https://hackillinois.github.io/adonix-metadata/config.json",

/* OAuth, Keys, & Permissions */

DB_URL: `mongodb+srv://${requireEnv("DB_USERNAME")}:${requireEnv("DB_PASSWORD")}@${requireEnv("DB_SERVER")}/`,

GITHUB_OAUTH_ID: requireEnv("GITHUB_OAUTH_ID"),
Expand Down

0 comments on commit 187cf7b

Please sign in to comment.