(1) باب كَرَاهَةِ شِرَاءِ الإِنْسَانِ مَا تَصَدَّقَ بِهِ مِمَّنْ تَصَدَّقَ عَلَيْهِ
Salim reported from Ibn Umar (Allah be pleased with them) that 'Umar donated a horse in the path of Allah and then found it being sold, and he decided to buy that. He asked Allah's Apostle (ﷺ) about it, whereupon Allah's Messenger (ﷺ) said:
Umar, do not get back what you gave as charity.
Reference: Sahih Muslim 1621 c
In-book reference: Book 24, Hadith 7
USC-MSA web (English) reference(deprecated numbering scheme): Book 12, Hadith 3954