What is the meaning of [The sun is never the worse for shining on a dunghill]

Good people are not corrupted by their surroundings.