Abu Musa was once served a chicken, and one of the men present moved away from it.Abu Musa asked, "What is the matter with you?"The man replied, "I saw it eating something filthy, so I swore I would never eat it."Abu Musa said, "Come closer and eat, for I saw the Messenger of Allah ﷺ eating it," and he instructed him to make expiation for his oath.
أخبرنا محمد بن منصور قال حدثنا سفيان قال حدثنا أيوب عن أبي قلابة
أن أبا موسى أتي بدجاجة فتنحى رجل من القوم فقال ما شأنك قال إني رأيتها تأكل شيئا قذرته فحلفت أن لا آكله فقال أبو موسى ادن فكل فإني رأيت رسول الله ﷺ يأكله وأمره أن يكفر عن يمينه
Muslim narrated it, Oaths, chapter on the recommendation for one who swears an oath and then sees something better than it, etc., h: 9/1649, from the hadith of Sufyan bin Uyayna. And Bukhari, Distribution of the Khums, chapter, and among the evidence that... etc., h: 3133, from the hadith of Ayub Sakhtiyani, through him. It is also in Al-Kubra, Khums for the Muslims' emergencies, h: 4858.