Critical Bug: "Undo" action deletes entire folders after task completion

Describe the request

Hi Cursor team,

I’ve discovered a very dangerous bug. When I finish a series of tasks and then use the “Undo” button, instead of just reverting the last code change, Cursor sometimes deletes the entire folder.

This is a major data safety issue. “Undo” should only affect code edits, it should never have the power to wipe out a directory structure. It has happened to me more than once and it’s quite stressful to see your whole work disappear with one click.

Since I’m basically doing “extreme QA testing” for you at this point, I think a free month of Cursor Pro (or more!) would be a great way to compensate for the heart attacks I’ve had while using the undo button. :wink:

Please look into this as a priority. Let me know if you need specific logs to track why the undo stack is triggering folder deletions.

Operating System (if it applies)

Windows 10/11

1 Like

Hey, thanks for the request. This is a known issue. There are a few similar reports (for example: Undo changes deleted entire repo). The team is working on improving Undo behavior in Agent Review.