Among the supplications of the Prophet ﷺ on the day of Hunayn was, "O Allah, if You will, You shall not be worshipped after this day."
حدثنا يزيد بن هارون أخبرنا حميد
كان من دعاء النبي ﷺ يوم حنين اللهم إن شئت أن لا تعبد بعد اليوم
Its isnad is sahih. Bukhari related the hadith 4/49 in the Book of Jihad, in the chapter on what was said about the Prophet's ﷺ armor, from Ibn Abbas, and Muslim 3/1384 no. 1763 in the Book of Jihad, in the chapter on reinforcement by the angels, both giving it at length, and the meaning becomes clear through its fuller version. Its meaning is, if You wish to defeat us, then You will never be worshipped on earth after us, because there would be no one left to affirm Allah's oneness and worship Him besides them at that time.