That's great advice, with one caveat, as from what I have read it is a boss/manager causing the difficulty...
- if a disgruntled manager can only ruin your "now", roll with it as above an adapt if conditions change...
- if you have some future plan pending (pension, etc) that could be scuttled if the manager decides to solve "their problem" by giving you the opportunity to find a new job unexpectedly, you need to play the long game and try not to be the manager's problem.
That is sort of the golden handcuffs of employment that keep us in difficult situations ... The promise of equity, benefits, retirement, pensions, etc otherwise there would be a lot more turnover instead of people putting up with the suck for the long-term goal.
Just my two cents