Creationists sometimes argue that Darwinism is wrong because the Nazis used it as a rationale for their eugenics program.
We call it a "genetic fallacy" if we try to claim that a theory is wrong because the person who discovered it was evil or unworthy. The theory has to be judged on its own without regard to who or what discovered it.
In this case the Nazis did not discover evolution, but (by many accounts) picked it up and adopted it as the truth, and possibly even employed its principles.
Just because Hitler liked it does not in any way imply that the theory is wrong. This might be a red herring because it is simply immaterial to whether evolution is true or not. But it seems that this is a special way of insinuating that something is evil because it was adopted and used by something or someone evil. It is a kind of "sin by association"
I looked through a couple of lists of fallacies and did not find one that captured this idea.