إِنَّمَا التَّوبَةُ عَلَى اللَّهِ لِلَّذينَ يَعمَلونَ السّوءَ بِجَهالَةٍ ثُمَّ يَتوبونَ مِن قَريبٍ فَأُولـٰئِكَ يَتوبُ اللَّهُ عَلَيهِم ۗ وَكانَ اللَّهُ عَليمًا حَكيمًا
God accepts the repentance of those who do evil in ignorance and then repent shortly after that. To them, God will grant forgiveness. God is All-Knowing, All-Wise.