🐛 fix .env file not loading

This commit is contained in:
Flam3rboy
2021-06-23 19:15:37 +02:00
parent e4fc61dc34
commit c845d19226
3 changed files with 411 additions and 338 deletions
+2 -1
View File
@@ -1,7 +1,8 @@
import { CDNServer } from "./Server";
import dotenv from "dotenv";
dotenv.config();
import { CDNServer } from "./Server";
if (process.env.STORAGE_LOCATION) {
if (!process.env.STORAGE_LOCATION.startsWith("/")) {
process.env.STORAGE_LOCATION = __dirname + "/../" + process.env.STORAGE_LOCATION;