When the cold was severe, the Messenger of Allah ﷺ would pray early, and when the heat was severe, he would delay the prayer until it cooled down. This refers to the Friday prayer.
كان رسول الله ﷺ إذا اشتد البرد بكر بالصلاة وإذا اشتد الحر أبرد بالصلاة. يعني الجمعة.
Bukhari related it in the book of Jumuah (906) via the route of Abu Khaldah, who is Khalid bin Dinar, who said, "I heard Anas bin Malik," and then narrated the hadith. Bukhari said, "Yunus bin Bukayr said, Abu Khaldah informed us, he said, 'The commander led us in the Friday prayer, then said to Anas, may Allah be pleased with him, "How did the Prophet ﷺ use to pray Dhuhr?"'" The commander was Hakam bin Abu Aqeel Thaqafi.Ibn Khuzayma related it (1842) via the route of Harmi bin Umara, who said, Abu Khaldah narrated to me, he said, "I heard Anas bin Malik, and Yazid Dabbi called out to him on a Friday during the time of Hajjaj, saying, 'O Abu Hamza! You witnessed the prayer with the Messenger of Allah ﷺ, and you have witnessed the prayer with us, so how did the Messenger of Allah ﷺ use to pray?'" He said... and he narrated the same account.