Does the Lord always protect the righteous from the unrighteous?

Alma 60:12-13


Alma 60:12-13
12. Do ye suppose that, because so many of your brethren have been killed it is because of their wickedness? I say unto you, if ye have supposed this ye have supposed in vain; for I say unto you, there are many who have fallen by the sword; and behold it is to your condemnation;
13. For the Lord suffereth the righteous to be slain that his justice and judgment may come upon the wicked; therefore ye need not suppose that the righteous are lost because they are slain; but behold, they do enter into the rest of the Lord their God.