A report indicating that a person's abandonment of some prohibitions for the sake of Allah, the Exalted, when they are able to commit them, may bring hope for forgiveness for past sins.
IBNHIBBAN 387:
from Ibn ʿUmar —
[Machine] "I heard the Prophet ﷺ say more than twenty times, 'Dhul-Kifl, from the Children of Israel, did not hesitate about anything, so he desired a woman and fell into a sin with her. He gave her sixty dinars. When he left her, she cried and repented. Dhul-Kifl regretted his actions and died that same night. In the morning, they found a note on his door saying, 'Indeed, Allah has forgiven you.'"
ابن حبّان ٣٨٧:
عن ابن عمر —
سَمِعْتُ النَّبِيَّ ﷺ أَكْثَرَ مِنْ عِشْرِينَ مَرَّةً يَقُولُ «كَانَ ذُو الْكِفْلِ مِنْ بَنِي إِسْرَائِيلَ لَا يَتَوَرَّعُ مِنْ شَيْءٍ فَهَوِيَ امْرَأَةً فَرَاوَدَهَا عَلَى نَفْسِهَا وَأَعْطَاهَا سِتِّينَ دِينَارًا فَلَمَّا جَلَسَ مِنْهَا بَكَتْ وَأُرْعِدَتْ فقَالَ لَهَا مَا لَكِ؟ فَقَالَتْ إِنِّي وَاللَّهِ لَمْ أَعْمَلْ هَذَا الْعَمَلَ قَطُّ وَمَا عَمِلْتُهُ إِلَّا مِنْ حَاجَةٍ قَالَ فَنَدِمَ ذُو الْكِفْلِ وَقَامَ مِنْ غَيْرِ أَنْ يَكُونَ مِنْهُ شَيْءٌ فَأَدْرَكَهُ الْمَوْتُ مِنْ لَيْلَتِهِ فَلَمَّا أَصْبَحَ وَجَدُوا عَلَى بَابِهِ مَكْتُوبًا إِنَّ اللَّهَ قَدْ غَفَرَ لَكَ»