[Machine] A man said, "O Messenger of Allah, will a person be held accountable for what they did in pre-Islamic times?" He replied, "Whoever does good in Islam will not be held accountable for what they did in pre-Islamic times, and whoever does evil in Islam will be held accountable for both the past and present."
رَجُلٌ يَا رَسُولَ اللَّهِ أَيُؤَاخَذُ الرَّجُلُ بِمَا عَمِلَ فِي الْجَاهِلِيَّةِ؟ قَالَ «مَنْ أَحْسَنَ فِي الْإِسْلَامِ لَمْ يُؤَاخَذْ بِمَا كَانَ عَمِلَ فِي الْجَاهِلِيَّةِ وَمَنْ أَسَاءَ فِي الْإِسْلَامِ أُخِذَ بِالْأَوَّلِ وَالْآخِرِ»