Abu Huraira narrated to us ahadith from Messenger of Allah ﷺ and out of these one is that Messenger of Allah ﷺ said: None amongst you should make a request for death, and do not call for it before it comes, for when any one of you dies, he ceases (to do good) deeds and the life of a believer is not prolonged but for goodness. (Using translation from Muslim 2682)
عَنْ رَسُولِ اللهِ ﷺ أَنَّهُ قَالَ لَا يَتَمَنَّى أَحَدُكُمُ الْمَوْتَ وَلَا يَدْعُو بِهِ مِنْ قَبْلِ أَنْ يَأْتِيَهُ إِلَّا أَنْ يَكُونَ قَدْ وَثِقَ بِعَمَلِهِ فَإِنَّهُ إِنْ مَاتَ أَحَدُكُمُ انْقَطَعَ عَنْهُ عَمَلُهُ وَإِنَّهُ لَا يَزِيدُ الْمُؤْمِنَ عُمْرُهُ إِلَّا خَيْرًا