The Messenger of Allah ﷺ prayed and then delivered a sermon, in which he ordered anyone who had slaughtered before the prayer to slaughter again. He then mentioned the rest, similar to the hadith of Ibn Ulayyah.
حدثنا محمد بن عبيد الغبري حدثنا حماد بن زيد حدثنا أيوب وهشام عن محمد
أن رسول الله ﷺ صلى ثم خطب فأمر من كان ذبح قبل الصلاة أن يعيد ذبحا ثم ذكر بمثل حديث ابن علية