cognovi-ai / the-cdj

The Cognitive Distortion Journal (CDJ) is a smart journaling tool that helps remedy distorted thinking. It can feel impossible to follow the CBT technique of labeling and reframing distorted thinking when you've been thinking this way your whole life. The CDJ can help with that 🧠✨ -- v2 is in development!
https://thecdj.app
3 stars 0 forks source link

Connect to MongoDB Atlas in production. #68

Closed hiyaryan closed 10 months ago

hiyaryan commented 10 months ago

This PR adds code to setup the database in production. The MongoDB Atlas service will be used when NODE_ENV is production, otherwise, a local MongoDB will be used in development and testing.

hiyaryan commented 10 months ago

Testing performed on server successfully connects to Atlas. Testing performed includes creating a new account, and writing a new entry. Then a login was attempted a second time with the same credentials successfully logging in again. Additionally, the database was inspected on Atlas with the recently added user data.