This hadith has been transmitted on the authority of Ibn Umar with a slight variation of wording (and the wording) that Allah's Messenger (ﷺ) said this on the pulpit
Hadith No. 6436
Sahih Muslim