The Messenger of Allah ﷺ said, "When you pray after the Friday prayer, pray four rakats. If something hurries you, then pray two rakats and another two rakats when you return."Ibn Idris said, "I do not know whether this is part of the hadith of the Messenger of Allah ﷺ or not."
حدثنا ابن إدريس قال سمعت سهيل بن أبي صالح يذكر عن أبيه
قال رسول الله ﷺ إذا صليتم بعد الجمعة فصلوا أربعا فإن عجل بك شيء فصل ركعتين وركعتين إذا رجعت قال ابن إدريس ولا أدري هذا من حديث رسول الله ﷺ أم لا