My student medic dd says that medical staff are not allowed to wear nail polish because it harbours germs at the edges. I'm not sure if the same applies to patients. Nail polish also used to be considered a fire risk, though that may not be the case nowadays.
I had had gel nails applied to fingers and toes for a holiday just hours before I fell and broke my leg, which meant I spent ten days in hospital instead of in the Caribbean! I had an operation to pin my leg but the nail polish had to stay as there was no way to remove it. Everyone on the staff knew who I was as soon as they saw the fancy nails - 'ooh, you're the lady who was going on holiday!'
I'd had my hair done that day, too, so was very fancy for a stay in hospital, although I'd also had on my older underwear, having packed my decent stuff - oh the shame of having to have your greying knickers cut off you!