I think you're referring to Halo and Horns Effect by Edward Thorndike.
It is a cognitive bias that causes you to allow one trait, either good (halo) or bad (horns), to overshadow other traits, behaviors, actions, or beliefs.
If you perceive a celebrity, for example, as kind, approachable, and talented you might think that he has no flaws and be free from any criminal liability - that is Halo Effect. For example, we find Michael Jackson as very talented and one of a kind performer. However, some people cannot believe and won't accept the fact that he sexually abused a child in 1993. Those people won't accept this fact because they were drawn on the good image of MJ before.
On the other hand, if you find a person ugly and lazy you perceive them as pest in the society and have no dreams for their lives - that is Horns Effect. One big example of this is the perception of everybody about Floyd Mayweather, Jr. We find him arrogant and cheater especially in the field of Boxing and always thinks of his money. But that doesn't mean he is not nice to his friends and don't attend to any religious activities.
There goes a saying, "First impression last". Some people, including me, believe that first impressions do not last, but some cannot get over with it.