Sahih al-Bukhari 6696
Sahih al-Bukhari · Book 83: Oaths and Vows · To vow for to be obedient to Allah
Narrated `Aisha:
حَدَّثَنَا أَبُو نُعَيْمٍ ، حَدَّثَنَا مَالِكٌ ، عَنْ طَلْحَةَ بْنِ عَبْدِ الْمَلِكِ ، عَنِ الْقَاسِمِ ، عَنْ عَائِشَةَ ـ رضى الله عنها ـ عَنِ النَّبِيِّ صلى الله عليه وسلم قَالَ " مَنْ نَذَرَ أَنْ يُطِيعَ اللَّهَ فَلْيُطِعْهُ، وَمَنْ نَذَرَ أَنْ يَعْصِيَهُ فَلاَ يَعْصِهِ " .
The Prophet (ﷺ) said, "Whoever vows that he will be obedient to Allah, should remain obedient to Him; and whoever made a vow that he will disobey Allah, should not disobey Him."