Hazrat Aisha, Allah be pleased with her, narrates that the Holy Prophet, peace and blessings of Allah be upon him, said:
“No calamity befalls a Muslim but that Allah expiates some of their sins because of it, even though it were the prick they receive from a thorn.”
(Sunan al-Bukhari)