It is narrated on the authority of Abu Huraira radiallahu anhu:
The Messenger of Allah peace be upon him observed: Verily Allah forgave my people the evil promptings which arise within their hearts as long as they did not speak about them or did not act upon them.
So, at times if there is a sense of evil in hearts, we must immediately remember this hadith and try not to say and do on such evil things.