How did that person reach the conclusion that it was infected due to fermenting in plastic?
Yeah that diagnosis seems suspect. If the comments were misinterpreted I could see how a suggestion (i.e. "check plastic vessels for scratches") could be taken as a prescription. Were these judges comments on a competition scoresheet, or just a judge tasting your beer and offering an opinion?
I am not aware of any specific contaminants that are more likely to exist in plastic vessels. The comments about scratches being potential hiding places are certainly valid, but as plenty of accomplished brewers have stated here, they can and do regularly make great clean beer with plastic.
The most common off flavors I can think of that are associated with the word plastic (but not with fermenting in plastic) are:
1) Chlorophenols - often described as tasting like plastic or medicinal flavors; common causes are related to chloramine or chlorine (usually from water or incomplete rinsing of chlorine-based sanitizers)
2) Actual plastic taste from hot liquid in vinyl tubing
Of course there are contaminants like wild yeast that can have a plastic tasting off flavor as well.
Before changing up a bunch of equipment, I recommend investing a little more effort into running down what the initial off flavor was and any process differences that could account for its absence in your newer beer.