Hadith 1537
وَعَن أبي هُرَيْرَة وَأبي سَعِيدٍ عَنِ النَّبِيِّ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ قَالَ: «مَا يُصِيبُ الْمُسْلِمَ مِنْ نَصَبٍ وَلَا وَصَبٍ وَلَا هَمٍّ وَلَا حُزْنٍ وَلَا أَذًى وَلَا غَمٍّ حَتَّى الشَّوْكَةُ يُشَاكُهَا إِلَّا كَفَّرَ اللَّهُ بهَا من خطاياه»
He and Abu Sa'id reported the Prophet as saying, “No Muslim is afflicted by difficulty, continuous pain, anxiety, grief, injury, or care, or even by a thorn with which he is pierced, without God thereby making an atonement for his sins.” (Bukhari and Muslim.)