Sayyiduna Mu'adh bin Jabal (may Allah be pleased with him) says that the Messenger of Allah (peace and blessings be upon him) said to me: "O Mu'adh! Of all that Allah Almighty has created on the face of the earth, the most hateful thing to Allah is divorce, and of all that Allah has created on the face of the earth, the most beloved thing to Allah Almighty is freeing (slaves). When a man says to his slave: 'You are free, In sha' Allah (if Allah wills)', he becomes free, and the exception is of no benefit; and when a man says to his wife: 'Anti taliq in sha' Allah' (You are divorced if Allah wills), the divorce does not take effect because of the exception being present."
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الخلع والطلاق / 15120