I also left after they ordered us back to the office.
The company (mid sized, a few thousand employees) was stagnant for many years and losing employees faster than employing them because of the bad management. Then they fired all the people (around 50) from a specific location that we were working with, very senior and really great, that i learned a lot from. From a team of 15, we were left 3. Then one of the colleagues got promoted to management, the other left, and I was the only one working on that product.
For context, the company had two very similar products, and wanted to migrate users of one to the other. Instead of providing a technical solution, I suppose they decided to simply make the support customers were paying for really awful, so customers wouldn't renew.
Other than the lack of manpower to maintain the product, infrastructure and also deal with all the customer escalations, it was fine as a workplace... My direct managers understood the situation and made a lot of effort to shield workers from the shitty upper management. I wasn't stressed at all, and just doing my job.
Then at the end of the pandemic, the company got bought by another. And things turned to shit... They fired a lot of people, especially management where they kept only the bootlickers of the new executives. I ended up working on 2 understaffed projects instead of 1 - both the product being replaced, and its replacement. And they made us come back to the office.
So I left.
And also legacy... If something is already written in assembly and you want to add a feature, you're not going to completely rewrite it.