"We were with the Messenger of Allah ﷺ and the Iqamah for prayer was said. The Messenger of Allah ﷺ stood up and one group stood behind him while another group faced the enemy. He led those who were behind him in prayer, bowing once and prostrating twice. Then they went and took the place of those who had been facing the enemy, and that group came and the Messenger of Allah ﷺ led them in prayer, bowing once and prostrating twice. Then the Messenger of Allah ﷺ said the taslim and those who were behind him said the taslim, as did the other group." (Using translation from Nasāʾī 1546)
«كُنَّا مَعَ النَّبِيِّ ﷺ فَأُقِيمَتِ الصَّلَاةُ فَقَامَ رَسُولُ اللهِ ﷺ وَقَامَتْ خَلْفَهُ طَائِفَةٌ وَطَائِفَةٌ مُوَاجِهَةٌ الْعَدُوَّ فَصَلَّى بِالَّذِينَ خَلْفَهُ رَكْعَةً وَسَجَدَ بِهِمْ سَجْدَتَيْنِ ثُمَّ إِنَّهُمُ انْطَلَقُوا فَقَامُوا مَقَامَ أُولَئِكَ الَّذِينَ كَانُوا فِي وَجْهِ الْعَدُوِّ وَجَاءَتْ تِلْكَ الطَّائِفَةُ فَصَلَّى بِهِمْ رَسُولُ اللهِ ﷺ رَكْعَةً وَسَجَدَ بِهِمْ سَجْدَتَيْنِ ثُمَّ إِنَّ رَسُولَ اللهِ ﷺ سَلَّمَ فَسَلَّمَ الَّذِينَ خَلْفَهُ وَسَلَّمَ أُولَئِكَ»