The Messenger of Allah ﷺ said on the day of Uhud, "Allah, if You so will, You shall not be worshipped on earth."
أن رسول الله ﷺ كان يقول يوم أحد: اللهم إنك إن تشأ، لا تعبد في الأرض.
Muslim narrated it in the Book of Jihad and Expeditions (1743:23) from Hajjaj bin Shayr, who said, "Abdul-Samad narrated to us, Hammad narrated to us, from Thabit, from Anas," and he related it.