# Environment editor clears .env file data automatically

**Project:** Bugs | **Board:** Live | **Votes:** 1
**URL:** https://roadmap.ploi.io/projects/7-bugs/items/1401-environment-editor-clears-env-file-data-automatically

---

I am reporting a bug with the built-in Environment editor. Occasionally, the `.env` file is being wiped completely (becoming an empty file) under the following conditions:

Scenario A: Opening the editor to view the `.env` and then closing/navigating away without making changes.
Scenario B: Clicking the "Save" button even when no changes were made to the text.

It seems like a sync issue where the editor saves an empty state before the actual file content has finished loading into the window. This causes the site to crash as the environment variables disappear.


