Sheikh Ahmad al-Rashîd
First, some words of advice are in order. When a person gives something to a relative, a neighbor, a traveling companion, or any another person as a means of assistance, he must make sure that he does so as an act of devotion to Allah. He should be seeking his reward for it from his Lord.
Allah says, describing to us the attitude that we should have when we give to others: “We only provide you this food seeking Allah’s countenance. We do not want from you any reward or thanks.” [Sûrah al-Insân: 9]
A Muslim should intend by all of his works the attainment Allah’s pleasure, because whatever other people might possess is something transient while what is with Allah is permanent and enduring.
This is exactly what happened to the person you describe in your question who gave some assistance to his friend and then had a falling out with him. Whatever worldly benefit he could have hoped to attain from his friend by giving that assistance to him was lost when the two people had their disagreement. However, had he given that assistance purely for the sake of Allah, then most surely Allah does not let the reward of such a good deed go to waste.
With respect to the question itself, it is unlawful for one who bestows a gift upon another to demand the return of that gift. Once the gift reaches the hands of the recipient, there is no way for the person to ask for it back, regardless of the reason for which he wishes to do so.
The Prophet (peace be upon him) made this clear when he said: “A person who secures the return of his gift is like a person who swallows his own vomit.” In one narration of the hadîth, it reads: “We have no one comparable in badness. A person who secures the return of his gift is like a dog that swallows its own vomit.” [Sahîh al-Bukhârî (2589) and Sahîh Muslim (1622)]
The Prophet (peace be upon him) also said: “No one who gives a gift has the right to demand it back, except for the father in what he gives to his child.” [Sunan al-Tirmidhî (1299), Sunan Abî Dâwûd (3539), Sunan al-Nasâ’î (3690), and Sunan Ibn Mâjah (2377)]
In consideration of the fact that a person has no legal right to demand that the return of what he has given as a gift, he incurs sin by making such a demand, since he is asking something that is unlawful.
Likewise, the recipient of the gift is under no legal obligation to return it and he incurs no sin for his refusal to do so. Upon receipt of the gift, it becomes his exclusive property and no one else has a share in the property rights that he has over it.
Source: Islam Today