Most folks now consider discriminating against people because of their race, color, culture, age, sex etc. wrongful, unjust or unethical. At one time, though, being discriminate was deemed a good thing but that was when the idea was used to mean something like tasteful, discerning, even aware. But then it became something objectionable when people discriminated between others based on certain features that were irrelevant for purposes of deciding someone's merits or worth as a professional or citizen.
Yet even now most folks have no problem with one's having a favorite color, flower, ice cream, brand of car, hairdo, or apparel, etc. That means, of course, that in practice one will be drawn to these favorites while avoiding what one doesn't find attractive or appealing – much of shopping pertains to picking favorites and avoiding what's not favored. There is hardly anyone to whom this doesn't apply and there is nothing wrong with it at all. This is so even when it is acknowledged that such tastes and preferences are quite arbitrary or subjective, not based on any sort of objective standards.
In contrast, it is also well and widely understood that when it comes to professional choices, it is indeed mostly wrong or unethical to let one's tastes or preferences make a big difference.
My dentist's hair cut might not appeal to me but what matters is how good he is at dentistry. A teacher whose wardrobe is unappealing doesn't lose points as a teacher for that. Nor is a student to be graded down for the color of his or her shoes. And the same thing holds across the board. (Of course, it is possible that someone's tastes will clash with one's own so drastically that one just cannot bear it!)
Now the same might also hold for race. There may be nothing amiss with preferring the skin color black to white or the other way around, so in personal matters this will be influential while in professional matters it should not be. One isn't a racist for liking some skin colors more than others unless one lets this be a factor in judging people's performance, worth, or qualification for citizenship. But otherwise acting on one's preferences is no different from selecting favorite flowers or sofas and the like.
Yes, there are many areas in human relations when it is inappropriate to invoke mere preferences as one decides for or against someone. When one judges a competition in, say, technology or sports, all that may count is what is relevant while what isn't needs to be left out of consideration. That is what justice demands. But life isn't all about justice. It isn't unjust for me to prefer tulips to roses, cabbage to broccoli, stake to fish or tall women to short ones.
All of this is pretty much common sense and widely acknowledge in practice even if careless rhetoric tends to go against some of it. (I am not considering here being judgmental based on religious or political convictions. Those can be well founded and need show no prejudice at all.) In dating, nearly everyone but a fanatic egalitarian will base selection on one's preferences, tastes, etc., at least to start with. And few will feel any qualms about it – guilt for liking tall rather than short dates – although here and there one learns of some who do feel guilty for not preferring dates who are, say, overweight or speak with a heavy foreign accent.
The reason there is much concern about making selections based on race, color or sex is that such selections often concern hiring, promoting, including or excluding people who should be judged based on skill, competence, and other objective factors. In those matters reliance of tastes and preferences can be blatantly unjust, while in choosing a date it would not be.
A problem with getting all this wrong is that condemning those who act on their preferences often leads to people feeling guilty, seeing themselves as acting unjustly, as even harming people, whereas that's not so at all. It is just that it is clearly wrong in certain cases to invoke one's tastes and preferences, namely where what ought to count is the qualification one has for specific tasks or roles. But basing one's preferences for other people on one's tastes or preferences is entirely acceptable when kept within proper bounds.