Setting boundaries on an organization's objectives is certainly a worthwhile thing to do, because coordination is hard and any alignment helps, but it is just going to reflect to consensus of the leadership regardless.
If a founder of a lunch restaurant starts out by saying "hello everyone, I'm here to make the best lunches possible but only for southern white people" I suspect, given my experience with lunches on three continents and in 37 states in the US, that he is going to have a hard time finding people who would actually be able to make good lunches.
Which is the point.
This does two things: it focuses people on what the actual mission of their company is or should be, and it can expose the kinds of missions that are nuts, or counter-productive, or just plain bad.
Which sounds fine, but Woolworth's chose not to serve Black Americans. This was legal[0]. With the benefit of hindsight, we can claim that refusing to serve Black people was indeed "taking a side", but there were places where supporting the pro-integration people was breaking the law. And refusing to serve Black people, until they staged sit ins, didn't appear to be taking a side, because it wasn't uncommon. It was the way most places worked.
Even the mission to "serve everyone a sandwich" doesn't require addressing segregation, you can have separate lunch counters and serve everyone. Perhaps that's fine, people at the time certainly thought it was.
[0]: https://www.history.com/topics/black-history/the-greensboro-...
Idk, "we make [my edit: great] sandwiches", which sounds like a great mission, seems very much entwined with who gets to eat said sandwiches - especially if they're delicious. Since if you are denying certain classes the right to enjoy your awesome sandwiches, your sandwiches probably aren't that great to begin with.
If I steel man your argument about having segregated counter space - that they'd excuse the segregation because if everyone has separate counter space to eat the sandwich the underlying differences don't matter -, what I'm left thinking about is that, well, the experience of having a great sandwich also has to do with the environment in which you eat it. Who wants to eat a delicious sandwich when you have to sit at a crappy table, with crappy chairs and bad service? No one, that's who.
And then we're back to my original point about artificially constraining the market for awesome sandwiches.
You say that someone could justify that. I'm saying they could also do the opposite. My point is that a "mission-oriented" code of conduct if you will allows the people who set the mission (read: leadership) to set the ethics too.
Fighting segregation can be part of the mission, or not. But if it isn't, you can't work on it.