I'm handling this through a combination of Tests and documentation-driven development ("scribe coding" instead of vibe coding).
* If it's important, it gets written into documentation somewhere. Functional requirements, technical requirements, ADRs, Lessons Learned, etc.
* Code comments and docstrings point back to documentation. Especially for bug fixes.
* Finally, bug fixes usually get new Unit Tests. The tests make sure if the bug resurfaces, it gets caught immediately.
I absolutely believe what you're describing: I've seen heard other people talk about this. I just don't experience it myself (I'd like to hope because of the extra steps I'm taking)