Sayyiduna Ibn Umar (may Allah be pleased with them both) said that the Messenger of Allah (peace and blessings be upon him) said: "Whoever swears and says 'In sha' Allah' (if Allah wills) has an exception." This is how I found it.
This hadith is known as marfu' only through the narration of Ayyub al-Sakhtiyani.
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الأيمان / 19915