Sura An-Noor

24:5

إِلَّا ٱلَّذِينَ تَابُوا۟ مِنۢ بَعْدِ ذَٰلِكَ وَأَصْلَحُوا۟ فَإِنَّ ٱللَّهَ غَفُورٌۭ رَّحِيمٌۭ

Men de som ångrar [vad de har gjort] och gottgör skadan skall undantas [från förbudet att vittna]. - Gud är alltid förlåtande, barmhärtig.

Tafsir 24:5

Except those who repent to Allah after what they have done and correct their actions, for Allah will accept their repentance and their testimony. Allah is Forgiving to those of His servants who repent and is Merciful to them.