"The Messenger of Allah traveled and fasted until he reached 'Usfan, then he called for a cup and drank durink the day when the people could see him. Hen he did not fast until he reached Makkah, and he conquered Makkah during Ramadan." Ibn 'Abbas said: "And the Messenger of Allah fasted until he reach Makkah, and he conquered Makkah during Ramadan." Ibn 'Abbas said: "And the Messenger of Allah fasted and broke his fast while traveling, so whoever wishes may fast, and whoever wishes may not fast." (Using translation from Nasāʾī 2314)
سَافَرَ رَسُولُ اللهِ ﷺ عَامَ الْفَتْحِ فِي رَمَضَانَ فَصَامَ حَتَّى بَلَغَ عُسْفَانَ ثُمَّ دَعَا بِإِنَاءٍ فَشَرِبَ نَهَارًا لِيَرَاهُ النَّاسُ ثُمَّ أَفْطَرَ حَتَّى دَخَلَ مَكَّةَ وَافْتَتَحَ مَكَّةَ فِي رَمَضَانَ قَالَ ابْنُ عَبَّاسٍ فَصَامَ رَسُولُ اللهِ ﷺ فِي السَّفَرِ وَأَفْطَرَ فَمَنْ شَاءَ صَامَ وَمَنْ شَاءَ أَفْطَرَ