David was living among the enemies of the Hebrews, the Philistines, and actually fighting with them. When they went to war with the Hebrews, David’s men went along, but were sent home because the other Philistine kings did not trust them. God spared David from having to fight his own people. David’s lies from a couple of days ago almost came back to haunt him, yet God delivered him from danger once again.
We often get ourselves into trouble because of our lies and sins, and that trouble often leads us to make even more wrong decisions, which causes even more trouble, and on and on. God does not approve of our lies or sins, but He still looks out for us, working all things for good.