I gave a horse to be used in the cause of Allah , but the man who had it neglected it. I wanted to buy it back from him, thinking he would sell it cheaply, so I asked the Messenger of Allah ﷺ about that.He said, "Do not buy it, even if he gives it to you for a single dirham, for the one who takes back his charity is like a dog that returns to its vomit."
أخبرنا محمد بن سلمة والحارث بن مسكين قراءة عليه وأنا أسمع عن ابن القاسم قال حدثنا مالك عن زيد بن أسلم عن أبيه قال سمعت
حملت على فرس في سبيل الله عز وجل فأضاعه الذي كان عنده وأردت أن أبتاعه منه وظننت أنه بائعه برخص فسألت عن ذلك رسول الله ﷺ فقال لا تشتره وإن أعطاكه بدرهم فإن العائد في صدقته كالكلب يعود في قيئه
Bukhari narrated it, in the Book of Zakat, Chapter: Is it permissible to buy back one's own charity? There is no harm if someone other than the giver buys it, hadith no. 1490, and Muslim, in the Book of Gifts, Chapter on the dislike of a person buying back what he gave in charity from the one to whom he gave it, hadith no. 1620, both from the hadith of Malik, through this same chain. It is also found in Muwatta (Yahya's version), 1/282, and in Kubra, no. 2397.