A long time ago, I knew a PC designer who worked for my company, and started moonlighting for another company nearby. The companies did not compete with each other in the product marketplace, only in the labor marketplace.
It happened that my company had some standard boilerplate prohibiting moonlighting, that the designer had signed when he started, and apparently forgot about or didn't read.
When the companies became aware of the situation, he lost both jobs.
;-----
Much longer ago, I worked for a tiny spinoff of a big multinational.
One of the multinational's designers moonlighted for us, but we couldn't call him at work; we had to send a message via his wife, because he was scared of losing his job.
The multinational had a strict no-moonlighting policy, and was known to enforce it ruthlessly.
The designer signed his drawings for us with only his initials.
The designer didn't know that his immediate supervisor also moonlighted for us.
The supervisor signed his drawings with the initials 'WK' for 'Who Knows', since his initials were unique enough to be possibly identifiable.
Mike Halloran
Pembroke Pines, FL, USA