It is narrated from Anas (may Allah be pleased with him) that he stated: The Messenger of Allah (ﷺ) reached Khaybar at night, and whenever the Messenger of Allah (ﷺ) would come to a people (for attack) at night, he would not attack them until morning. If he heard the call to prayer (adhan), he would not attack, but if they were not among those who prayed, he would attack them at dawn. When morning came, he (ﷺ) mounted, and the Muslims also mounted. The people of the settlement came out with their baskets and containers. When they saw the Messenger of Allah (ﷺ), they said: "Muhammad (ﷺ) and (his) army." The Messenger of Allah (ﷺ) said: "Allahu Akbar, Khaybar is ruined. When we descend upon a people, then evil is the morning for those who have been warned (of the punishment of Hell)." Anas (may Allah be pleased with him) said: I was riding behind Abu Talhah (may Allah be pleased with him), and my foot was touching the blessed foot of the Messenger of Allah (ﷺ).
Hadith Referenceمسند الإمام الشافعي / كتاب الجهاد وقسم الغنائم / 1740
Hadith Takhrijاخرجه البخارى الجهاد والسير ، باب دعاء النبي الى الاسلام والنبوة ..... الخ (2943)، (371)۔