ʿUmar bin Al-Khattab gave a horse to be ridden in Allah's Cause and then he found it being sold. He intended to purchase it. So, he consulted Messenger of Allah ﷺ who said, "Don't buy it and don't take back your gift of charity."
أَنْ يَبْتَاعَهُ فَسَأَلَ رَسُولَ اللَّهِ ﷺ فَقَالَ لاَ تَبْتَعْهُ وَلاَ تَعُدْ فِي صَدَقَتِكَ