Sahih Muslim , Book 6, Hadith 370 (In-Book) ⓘ
Salim b. Abdullah b. 'Umar reported: The Messenger of Allah (may peace he upon him) led on* of the two groups In one rak'ah of prayer in danger, while the other group faced the -enemy. Then they (the members of the first group) went back and replaced their companions who were facing the enemy. and then they (the members of the second group) came and the Messenger of Allah led them in one rak'ah of prayer. Then the Messenger of Allah pronounced salutation, and then they (the members of the Ant group) completed the rak'ah and they (the members of the second group) completed the rak'ah.
حَدَّثَنَا عَبْدُ بْنُ حُمَيْدٍ، أَخْبَرَنَا عَبْدُ الرَّزَّاقِ، أَخْبَرَنَا مَعْمَرٌ، عَنِ الزُّهْرِيِّ، عَنْ سَالِمٍ، عَنِ ابْنِ عُمَرَ، قَالَ صَلَّى رَسُولُ اللَّهِ صلى الله عليه وسلم صَلاَةَ الْخَوْفِ بِإِحْدَى الطَّائِفَتَيْنِ رَكْعَةً وَالطَّائِفَةُ الأُخْرَى مُوَاجِهَةُ الْعَدُوِّ ثُمَّ انْصَرَفُوا وَقَامُوا فِي مَقَامِ أَصْحَابِهِمْ مُقْبِلِينَ عَلَى الْعَدُوِّ وَجَاءَ أُولَئِكَ ثُمَّ صَلَّى بِهِمُ النَّبِيُّ صلى الله عليه وسلم رَكْعَةً ثُمَّ سَلَّمَ النَّبِيُّ صلى الله عليه وسلم ثُمَّ قَضَى هَؤُلاَءِ رَكْعَةً وَهَؤُلاَءِ رَكْعَةً .
also referenced under: Hadith 839 (Reference) & Book 4, Hadith 1824 (USC-MSA)