Narrated Anas bin Malik: Allah's Messenger ﷺ (pbuh) offered the Fajr prayer when it was still dark, then he rode and said, 'Allah Akbar! Khaibar is ruined. When we approach near to a nation, the most unfortunate is the morning of those who have been warned". The people came out into the streets saying, "Muhammad and his army". Allah's Messenger ﷺ vanquished them by force and their warriors were killed; the children and women were taken as captives. Safiya was taken by Dihya Al-Kalbi and later she belonged to Allah's Apostle go who married her and her Mahr was her manumission.
The story also serves as an example for us on how we should conduct ourselves during times of war; even though it may seem like a necessary evil at times, we must remember that there are limits to what is permissible according to Islamic teachings and never go beyond them when engaging in battle or conflict with others. We must always strive for justice while showing mercy whenever possible so as not to cause unnecessary suffering or hardship on innocent individuals caught up in a situation beyond their control.