Ibn Abbas has commented on the above-mentioned event, saying about the following holy verse:
“Men whom neither merchandise nor selling diverts from the remembrance of Allah and the keeping up of prayer and the giving of poor-rate; they fear a day in which the hearts and eyes shall turnabout; That Allah may give them the best reward of what they have done, and give them more out of His grace; and Allah gives sustenance to whom He pleases without measure” (24:37-38).
He says: The occasion of the revelation was that one day the Holy Prophet (P.B.U.H&H.P) gave Ali (A.S) three hundred dinars, which they had given to him as gift. Ali (A.S) said: I took the money and said to myself by Allah, I will give such a charity with these dinars that Allah will accept. When I completed the night prayer with Allah’s Messenger, I took a hundred dinars and left the mosque. On my way, I came across a woman to whom I gave one hundred dinars. The following day, people said, “Ali (A.S) has given charity to a corrupt woman!” It was a great sorrow for me.
The night of that day, I performed the night prayer, took a hundred dinars in my hand, left the mosque and said to myself, “By Allah! I will give a charity, which will be accepted by my Lord. I saw a man and gave away the one hundred dinars to him.” The following day, the people of Medina said, “Ali (A.S) has given away a hundred dinars to a thief.” Again a great sorrow came to me but said to myself, “By Allah! I will give a charity tonight that Allah will accept from me.”
So, I performed my night prayer with Allah’s Messenger and then left the mosque having a hundred dinars with me. I saw a man to whom I gave the money. The next day, the people Medina said, “Last night, Ali (A.S) gave a hundred dinars to a rich man.” Again, a great sorrow came to me.
I went to Allah’s Messenger and told him the event. The Holy Prophet (P.B.U.H&H.P) said: O Ali (A.S)! Gabriel says to you: Allah has accepted your charity and purified your acts: The one hundred Dinars you gave as charity was put at the disposal of a corrupt woman who repented to Allah and used the money as earnings for her living. She also intends to get married with this money.
The charity of the second night went to a thief who repented thereafter and used the money for running a business. The charity of the third night went to a rich man who had not paid alms (Zakat) for years. He went home and blamed himself saying, “How miser I am! This is Ali ibn Abi Talib (A.S) who gave away a hundred Dinars to me while he has nothing whereas I am a rich man who has not paid his obligatory alms (Zakat)!” So, he reckoned his alms (Zakat) and put it aside. It was for this reason that Allah revealed the above-mentioned verses.
(Al-Manaqib: 74/2)