Sayyiduna Abu Hurayrah (may Allah be pleased with him) said that the Messenger of Allah (peace and blessings be upon him) said: "Whoever dislikes an evil taking place in his presence is as though he were absent from it, and whoever was not present at the time of the evil but approved of it is as though he were present."
Only Yahya bin Abi Sulayman narrated it, and he is not strong.
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الصداق / 14553