He—may Allah Most High have mercy on him—was asked:
A man’s wife refused to have intercourse with him. Hurt by her refusal, he swore on pain of divorce, while she was pregnant, that he would not have intercourse with her after she gave birth. Would divorce take effect if he had intercourse with her after childbirth? Should the circumstance that provoked the oath be taken into account?
He replied:
If he has intercourse with her after childbirth, consideration must be given to his intention when swearing and to the reason for his oath. If he swore for a particular reason and that reason has ceased to exist, he has not broken his oath, according to the sounder of the two scholarly views within Ahmad’s school and others.
For someone may swear an oath concerning a particular matter for a specific reason: for example, he may swear not to enter a town because of injustice he witnessed there, and that injustice subsequently ceases; or he may swear not to speak to a certain person, whose sinful conduct subsequently ceases; and so forth. There are “two views” within Ahmad’s school and others as to whether he breaks his oath in such circumstances. The sounder view is that he does not, because urging and restraining through an oath are comparable to commanding and forbidding.
Thus, one who swears an oath to restrain himself or someone else is like one who forbids an act. If someone forbids entering a town or speaking to a particular person for a reason, and that reason subsequently ceases to exist, the prohibition ceases. This is like refraining from greeting a man first because he is a disbeliever, after which he embraces Islam; or refraining from entering a land because it is a land of war, after which it becomes a land of Islam; and similar cases. When a ruling is based on a particular cause, it ceases when that cause ceases.