They didn't have the policy for twenty years.
It doesn't matter if they didn't have the policy for 50 years. They have it now. At my work, I am required to dress a specific way. If I do not (or refuse) I am not complying with company policy. I could be fired. They can change whatever policy they want. I can either conform, or I can find another job.