Caution: Translations of Quran and Ḥadīth may lead to possible misapplications and misinterpretations. This site is intended for students of sacred knowledge that are proficient in comprehending classical Arabic and have a strong foundation in Islamic sciences. Also note that religious injunctions rely on several aspects beyond what one may glean through reading individual aḥādīth.
quran:17:11

And man supplicates for evil as he supplicates for good, and man is ever hasty.  

And man prays for ill, against himself and his family when he is frustrated, as ˹avidly as˺ he prays for good. And mankind is ever hasty, to pray against himself, without contemplating the consequence thereof.
القرآن:١٧:١١

وَيَدْعُ الْإِنْسَانُ بِالشَّرِّ دُعَاءَهُ بِالْخَيْرِ ۖ وَكَانَ الْإِنْسَانُ عَجُولًا  

{ويَدْعُ الإنسان بالشر} على نفسه وأهله إذا ضجر {دعاءه} أي كدعائه له {بالخير وكان الإنسان} الجنس {عجولا} بالدعاء على نفسه وعدم النظر في عاقبته.