The Messenger of Allah ﷺ ordered that the zakat al-fitr be paid before the people went out to the prayer.
حدثنا عتاب حدثنا عبد الله أخبرنا أسامة بن زيد عن نافع
أن رسول الله ﷺ أمر بزكاة الفطر أن تؤدى قبل خروج الناس إلى الصلاة
Its isnad is sahih. Abu Dawud reported it in 2:25-26 with an addition, that Ibn Umar used to pay it a day or two before that. Munziri said in 1544, Bukhari, Muslim, Tirmidhi, and Nasai also reported it, but their narration does not include Ibn Umar's practice.