]> git.p6c8.net - pcdenotes.git/blobdiff - pcdenotes/settings.py
Changed the way the .env file is loaded
[pcdenotes.git] / pcdenotes / settings.py
index db9476f1c3d4ee2ed7d4a420bc4b5db257f97e2a..5e82661fadc6233b1705e8bdacf0ad4c2f47ba08 100644 (file)
@@ -13,13 +13,14 @@ https://docs.djangoproject.com/en/3.2/ref/settings/
 from pathlib import Path
 
 from dotenv import load_dotenv, find_dotenv
-load_dotenv(find_dotenv())
 
 import os
 
 # Build paths inside the project like this: BASE_DIR / 'subdir'.
 BASE_DIR = Path(__file__).resolve().parent.parent
 
+# Load .env file
+load_dotenv(BASE_DIR / '.env')
 
 # Quick-start development settings - unsuitable for production
 # See https://docs.djangoproject.com/en/3.2/howto/deployment/checklist/

patrick-canterino.de