9 But these things we have said, as one might say them incidentally, concerning all the commandments. Now we must go on to that which is before us, and keep to the thread of what had been affirmed. “He that is angry with his brother without a cause shall be in danger of the judgment:” so He speaks. Thus He has not altogether taken the thing away: first, because it is not possible, being a man, to be freed from passions: we may indeed get the dominion over them, but to be altogether without them is out of the question.
Next, because this passion is even useful, if we know how to use it at the suitable time. See, for instance, what great good was wrought by that anger of Paul, which he felt against the Corinthians, on that well-known occasion; and how, as it delivered them from a grievous pest, so by the same means again he recovered the people of the Galatians likewise, which had fallen aside; and others too beside these. What then is the proper time for anger? When we are not avenging ourselves, but checking others in their lawless freaks, or forcing them to attend in their negligence.
And what is the unsuitable time? When we do so as avenging ourselves: which Paul also forbidding, said “Avenge not yourselves, dearly beloved, but rather give place unto wrath.” When we are contending for riches: yea, for this has he also taken away, where he says, “Why do ye not rather take wrong? Why do ye not rather suffer yourselves to be defrauded?” For as this last sort is superfluous, so is the first necessary and profitable. But most men do the contrary; becoming like wild beasts when they are injured themselves, but remiss and cowardly when they see despite done to another: both which are just opposite to the laws of the Gospel.
Being angry then is not a transgression, but being so unseasonably. For this cause the prophet also said, “Be angry, and sin not.”
Source: Homilies on the Gospel of St. Matthew (New Advent)