Bhagavad Gita Chapter 6.9
suhṛn-mitrāry-udāsīna-
madhyastha-dveṣya-bandhuṣu
sādhuṣv api ca pāpeṣu
sama-buddhir viśiṣyate
Translation
A person is considered still further advanced when he regards honest well-wishers, affectionate benefactors, the neutral, mediators, the envious, friends and enemies, the pious and the sinners all with an equal mind.