Sahih al-Bukhari 6719
Sahih al-Bukhari · Book 84: Expiation for Unfulfilled Oaths · To say: “In sha’ Allah” while taking an oath
Narrated Hammad:
حَدَّثَنَا أَبُو النُّعْمَانِ، حَدَّثَنَا حَمَّادٌ، وَقَالَ، " إِلاَّ كَفَّرْتُ يَمِينِي، وَأَتَيْتُ الَّذِي هُوَ خَيْرٌ ". أَوْ " أَتَيْتُ الَّذِي هُوَ خَيْرٌ، وَكَفَّرْتُ ".
the same narration above (i.e. 709), "I make expiation for my dissolved oath, and I do what is better, or do what is better and make expiation."