Hi Joshua, Thanks for the question. The Lord Jesus was teaching them a lesson. He said to Peter put up thy sword they that take the sword will die by it. We are never to use self defense and always to trust in the Lord to protect us. This is why Jesus said, if they smite you on right cheek to offer them your left cheek. We are to let God to fight out battles. God does not save by weapons of warfare in the natural. When seeking to save our lives we might hurt or kill someone else. We are to be harmless the sons of God. Harmless as doves. The battle is not our it's the Lord's!
1 Samuel 17:47 KJV
And all this assembly shall know that the LORD saveth not with sword and spear: for the battle is the LORD'S, and he will give you into our hands.