The Messenger of Allah ﷺ said, "Hasten to do good deeds before tribulations come like patches of a dark night. A man will wake up a believer and go to sleep an unbeliever, or go to sleep a believer and wake up an unbeliever, selling his religion for a trifle of worldly goods."
أن رسول الله ﷺ قال: بادروا بالأعمال فتنا كقطع الليل المظلم، يصبح الرجل مؤمنا ويمسي كافرا، أو يمسي مؤمنا ويصبح كافرا، يبيع دينه بعرض من الدنيا.
Muslim narrated it in the Book of Faith (118) through several routes from Ismail bin Jafar, who said, Ala told me, from his father, from Abu Hurairah, and he mentioned it.A similar version was narrated from Abu Umama in Ibn Majah (3954), which includes the words, "except one whom Allah has revived with knowledge." Its chain includes Ali bin Yazid, who is Alhani, and he is a narrator whose hadith is rejected.