The #MeToo era has brought new scrutiny to a wide range of workplace misconduct — from discrimination to sexual harassment to assault — that was ignored, tolerated or even covered up in some corners of corporate America.

Now, the abrupt firing of McDonald’s chief executive, Steve Easterbrook, over the weekend highlights how even consensual relationships between managers and subordinates are drawing greater scrutiny.

Many of the circumstances of Mr. Easterbrook’s dismissal remain unclear, but McDonald’s said on Sunday that its board had determined he engaged in a relationship that violated company policy. Its standards of business conduct prohibit employees with “a direct or indirect reporting relationship” from “dating or having a sexual relationship.”

“It is not appropriate to show favoritism or make business decisions based on emotions or friendships rather than on the best interests of the company,” the policy states.