Sahih Muslim , Book 45, Hadith 166 (In-Book)

Abu Huraira reported Allah's Messenger as saying: While a person was going along the path he found a thorny branch upon it. He pushed it to a side and Allah approved (this action) of his and (as a mark of appreciation) granted him pardon.

حَدَّثَنَا يَحْيَى بْنُ يَحْيَى، قَالَ قَرَأْتُ عَلَى مَالِكٍ عَنْ سُمَىٍّ، مَوْلَى أَبِي بَكْرٍ عَنْ أَبِي، صَالِحٍ عَنْ أَبِي هُرَيْرَةَ، أَنَّ رَسُولَ اللَّهِ صلى الله عليه وسلم قَالَ ‏ "‏ بَيْنَمَا رَجُلٌ يَمْشِي بِطَرِيقٍ وَجَدَ غُصْنَ شَوْكٍ عَلَى الطَّرِيقِ فَأَخَّرَهُ فَشَكَرَ اللَّهُ لَهُ فَغَفَرَ لَهُ ‏" ‏ ‏.‏

sunnah.com