I was taught that Russian Cossacks of at the end of the 1800s wore black with red vests and red-lined capes. The reason? To hide the blood. From a distance a wounded cossack would still look able to fight, and so might deter an attack.
A favored saying of young officers sprung from that bit of lore: "Never let them see you bleed." This was misapplied to mean that you should never show weakness in front of your people.
The question is more nuanced than that. Sometimes your people should see your weakness, sometimes they shouldn't. How do you know? By what you want them to do. Showing your weakness will give employees permission to have the same weakness.
So taking breaks, taking vacation days, or other ways that you rest and recuperate are good for them to see. You want them to rest periodically, so that they do good work. You want them to admit they can't do something, so you should admit it when you don't have the needed skills. Any weakness you want your people to be open about, you should too.
On the other hand, if you're just tired because of a late night, suck it up. If you have a cold and you're feeling miserable, try to hide it. If you're grumpy and want to lash out at people, don't. In all those cases, you need to consistently be a calm and reliable performer. Why? Because in similar situations you want your people either to do their job or take a day off.
Certainly you should never show petty weaknesses at work. Petulance, anger, sulkiness, self-pity -- all of those things have only negative impacts. If you're ever feeling that way, hide it.
Get rid of the old school image of leader as iron man. Instead, simply try to behave the way you want your team to act.
As always, it takes some judgment. But that's why you're the leader: because you have some.