.... yes thats right! If your friend does not return money he was not a person worth your friendship anyway! So you really did not loose a friend you only lost moeny, you see! And the extent of loss is what you paid to get the reality check.
Beside, a good friend will really not ask in the first place. And by-the-way, what kind of friend would you be if you did not know about his dire financial situation! In such a case you yourself will have to offer to help, obviously not expecting him to return. Essentially the extent of such an offer will be limited to the amount you can efford to simply give out.
Now what happens if the person who gives you the bad experience happens to be your own brother, for example! Well you can not write him off completely but good thing is that he will not come back to you again for any loan. So the cost of lifetime of peace is only to the extent of first-time loan.
Moral of the stroy - keep the amount lmited to the extent of what you can efford to loose. You will not be loser in the end, I bet.