Jesus was always hanging out with the wrong kind of people. He was accused of being friends of tax collectors and sinners (Mark 2:13-16), befriending lepers (Mark 1:40-42) who were literal outcasts as they had to stay outside the city and have no contact with people who did not have leprosy. He involved the tax collector, Matthew and even a revolutionary, Simon the Zealot as part of His apostleship team. Public opinion or peer pressure was not an issue for Jesus.
The religious leaders were always after Jesus for doing things that they did not approve of (Mark 2:18-3:6). How dare Jesus break their rules! Some of the best times Jesus had with people were with Samaritans whom the Jews considered to be the worst kind of people on earth, if they even considered Samaritans to be people. Jesus was a Jew and good Jews did not do anything with the despicable Samaritans.
So Jesus dealt with what people thought of Him because of the people He hung around with. Now, no matter who He came in contact with, He never changed His convictions and ...