Say that Ash works for Big Co. and goes on some kind of legally protected leave (FMLA leave, parental leave, etc.) because of some protected characteristic (such as having acquired a disability and/or child).
Ash's boss Brett is fully on board with following all applicable laws. But while Ash is gone, Brett notices... nothing. There is no measurable change in the productivity or performance of Brett's team or of the company in general. Tasks are getting done exactly as fast, the same number of widgets as ever are rolling out the door, and nobody is in the least inconvenienced by not having Ash around or not having Ash's job done. Brett can't help but conclude that whatever Ash is employed to do is not actually a thing worth doing.
But Brett only knows that Ash's job is unnecessary because Ash went out on protected leave.
Can Ash be laid off from their unnecessary job as a result of their protected leave revealing their job's unnecesariness?